aboutsummaryrefslogtreecommitdiffstats
path: root/packages/instant/src/util
diff options
context:
space:
mode:
Diffstat (limited to 'packages/instant/src/util')
-rw-r--r--packages/instant/src/util/error.ts4
-rw-r--r--packages/instant/src/util/etherscan.ts4
2 files changed, 6 insertions, 2 deletions
diff --git a/packages/instant/src/util/error.ts b/packages/instant/src/util/error.ts
index 0868414f0..844a28d8b 100644
--- a/packages/instant/src/util/error.ts
+++ b/packages/instant/src/util/error.ts
@@ -46,6 +46,10 @@ const humanReadableMessageForError = (error: Error, asset?: Asset): string | und
return `${assetName} is currently unavailable`;
}
+ if (error.message === AssetBuyerError.SignatureRequestDenied) {
+ return 'You denied this transaction';
+ }
+
return undefined;
};
diff --git a/packages/instant/src/util/etherscan.ts b/packages/instant/src/util/etherscan.ts
index ffb08a382..cfc2578a3 100644
--- a/packages/instant/src/util/etherscan.ts
+++ b/packages/instant/src/util/etherscan.ts
@@ -14,11 +14,11 @@ const etherscanPrefix = (networkId: number): string | undefined => {
};
export const etherscanUtil = {
- getEtherScanTxnAddressIfExists: (txnHash: string, networkId: number) => {
+ getEtherScanTxnAddressIfExists: (txHash: string, networkId: number) => {
const prefix = etherscanPrefix(networkId);
if (_.isUndefined(prefix)) {
return;
}
- return `https://${prefix}etherscan.io/tx/${txnHash}`;
+ return `https://${prefix}etherscan.io/tx/${txHash}`;
},
};