-
-
Notifications
You must be signed in to change notification settings - Fork 88
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[14.x] fix: support ethermint's EIP712 implementation #333
Changes from 1 commit
7d7cbc2
04eda48
19fa137
13ec413
fbf441f
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -462,7 +462,7 @@ | |
* | ||
* @param address - The address to validate and normalize. | ||
* @param req - The request object. | ||
* @returns {string} - The normalized address, if valid. Otherwise, throws | ||
Check warning on line 465 in src/wallet.ts GitHub Actions / Build, lint, and test / Lint (20.x)
Check warning on line 465 in src/wallet.ts GitHub Actions / Build, lint, and test / Lint (18.x)
Check warning on line 465 in src/wallet.ts GitHub Actions / Build, lint, and test / Lint (22.x)
|
||
* an error | ||
*/ | ||
async function validateAndNormalizeKeyholder( | ||
|
@@ -500,7 +500,7 @@ | |
*/ | ||
function validateVerifyingContract(data: string) { | ||
const { domain: { verifyingContract } = {} } = parseTypedMessage(data); | ||
if (verifyingContract && !isValidHexAddress(verifyingContract)) { | ||
if (verifyingContract && !(isValidHexAddress(verifyingContract) || verifyingContract == 'cosmos')) { | ||
Check failure on line 503 in src/wallet.ts GitHub Actions / Build, lint, and test / Build (20.x)
Check failure on line 503 in src/wallet.ts GitHub Actions / Build, lint, and test / Lint (20.x)
Check failure on line 503 in src/wallet.ts GitHub Actions / Build, lint, and test / Lint (20.x)
Check failure on line 503 in src/wallet.ts GitHub Actions / Build, lint, and test / Build (18.x)
Check failure on line 503 in src/wallet.ts GitHub Actions / Build, lint, and test / Lint (18.x)
Check failure on line 503 in src/wallet.ts GitHub Actions / Build, lint, and test / Lint (18.x)
Check failure on line 503 in src/wallet.ts GitHub Actions / Build, lint, and test / Lint (22.x)
|
||
throw rpcErrors.invalidInput(); | ||
} | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Needs adjusting of types as well.
(FWIW: The linting can also be run locally by
yarn lint
andyarn build
, and tests byyarn test
)There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thx. fixed