-
Notifications
You must be signed in to change notification settings - Fork 419
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'develop' into feat/new-user-import
- Loading branch information
Showing
23 changed files
with
371 additions
and
165 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
diff --git a/node_modules/@ledgerhq/hw-app-eth/lib-es/services/ledger/contracts.js b/node_modules/@ledgerhq/hw-app-eth/lib-es/services/ledger/contracts.js | ||
index 806a539..b488b25 100644 | ||
--- a/node_modules/@ledgerhq/hw-app-eth/lib-es/services/ledger/contracts.js | ||
+++ b/node_modules/@ledgerhq/hw-app-eth/lib-es/services/ledger/contracts.js | ||
@@ -19,7 +19,7 @@ export const loadInfosForContractMethod = (contractAddress, selector, chainId, u | ||
if (pluginBaseURL) { | ||
const url = `${pluginBaseURL}/plugins/ethereum.json`; | ||
data = yield axios | ||
- .get(`${pluginBaseURL}/plugins/ethereum.json`) | ||
+ .get(`${pluginBaseURL}/plugins/ethereum.json`, { timeout: 5000 }) | ||
.then(r => r.data) | ||
.catch(e => { | ||
log("error", "could not fetch from " + url + ": " + String(e)); | ||
diff --git a/node_modules/@ledgerhq/hw-app-eth/lib-es/services/ledger/erc20.js b/node_modules/@ledgerhq/hw-app-eth/lib-es/services/ledger/erc20.js | ||
index 16a933e..a2a0f1a 100644 | ||
--- a/node_modules/@ledgerhq/hw-app-eth/lib-es/services/ledger/erc20.js | ||
+++ b/node_modules/@ledgerhq/hw-app-eth/lib-es/services/ledger/erc20.js | ||
@@ -21,7 +21,7 @@ export const findERC20SignaturesInfo = (userLoadConfig, chainId) => __awaiter(vo | ||
return null; | ||
const url = `${cryptoassetsBaseURL}/evm/${chainId}/erc20-signatures.json`; | ||
const blob = yield axios | ||
- .get(url) | ||
+ .get(url, { timeout: 5000 }) | ||
.then(({ data }) => { | ||
if (!data || typeof data !== "string") { | ||
throw new Error(`ERC20 signatures for chainId ${chainId} file is malformed ${url}`); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
import { | ||
LedgerAction, | ||
OffscreenCommunicationTarget, | ||
} from '@/constant/offscreen-communication'; | ||
import { ledgerUSBVendorId } from '@ledgerhq/devices'; | ||
import Browser from 'webextension-polyfill'; | ||
|
||
export function initLedger() { | ||
navigator.hid.addEventListener('disconnect', ({ device }) => { | ||
if (device.vendorId === ledgerUSBVendorId) { | ||
Browser.runtime.sendMessage({ | ||
target: OffscreenCommunicationTarget.extension, | ||
event: LedgerAction.ledgerDeviceDisconnect, | ||
}); | ||
} | ||
}); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.