aboutsummaryrefslogtreecommitdiffstats
path: root/packages/contract-wrappers/src/utils
diff options
context:
space:
mode:
authorBrandon Millman <brandon.millman@gmail.com>2018-10-23 13:23:32 +0800
committerBrandon Millman <brandon.millman@gmail.com>2018-10-24 01:02:00 +0800
commitaf2bf053bc9cfe80618109dc10a90515d780cd25 (patch)
tree872e36f63bbb50496ff46128e437866df0588dc3 /packages/contract-wrappers/src/utils
parent117ee19370e56f3559b9b11b04becc5ad9c7d634 (diff)
downloaddexon-sol-tools-af2bf053bc9cfe80618109dc10a90515d780cd25.tar
dexon-sol-tools-af2bf053bc9cfe80618109dc10a90515d780cd25.tar.gz
dexon-sol-tools-af2bf053bc9cfe80618109dc10a90515d780cd25.tar.bz2
dexon-sol-tools-af2bf053bc9cfe80618109dc10a90515d780cd25.tar.lz
dexon-sol-tools-af2bf053bc9cfe80618109dc10a90515d780cd25.tar.xz
dexon-sol-tools-af2bf053bc9cfe80618109dc10a90515d780cd25.tar.zst
dexon-sol-tools-af2bf053bc9cfe80618109dc10a90515d780cd25.zip
feat(contract-wrappers): relax requirement for throwing `ContractWrappersError.SignatureRequestDenied`
Diffstat (limited to 'packages/contract-wrappers/src/utils')
-rw-r--r--packages/contract-wrappers/src/utils/constants.ts2
-rw-r--r--packages/contract-wrappers/src/utils/decorators.ts2
2 files changed, 2 insertions, 2 deletions
diff --git a/packages/contract-wrappers/src/utils/constants.ts b/packages/contract-wrappers/src/utils/constants.ts
index b89438592..c587ba526 100644
--- a/packages/contract-wrappers/src/utils/constants.ts
+++ b/packages/contract-wrappers/src/utils/constants.ts
@@ -14,5 +14,5 @@ export const constants = {
ZERO_AMOUNT: new BigNumber(0),
ONE_AMOUNT: new BigNumber(1),
ETHER_TOKEN_DECIMALS: 18,
- METAMASK_DENIED_SIGNATURE_PATTERN: 'MetaMask Tx Signature: User denied transaction signature',
+ USER_DENIED_SIGNATURE_PATTERN: 'User denied transaction signature',
};
diff --git a/packages/contract-wrappers/src/utils/decorators.ts b/packages/contract-wrappers/src/utils/decorators.ts
index 932b11785..a4207ae4c 100644
--- a/packages/contract-wrappers/src/utils/decorators.ts
+++ b/packages/contract-wrappers/src/utils/decorators.ts
@@ -30,7 +30,7 @@ const schemaErrorTransformer = (error: Error) => {
};
const signatureRequestErrorTransformer = (error: Error) => {
- if (_.includes(error.message, constants.METAMASK_DENIED_SIGNATURE_PATTERN)) {
+ if (_.includes(error.message, constants.USER_DENIED_SIGNATURE_PATTERN)) {
const errMsg = ContractWrappersError.SignatureRequestDenied;
return new Error(errMsg);
}