aboutsummaryrefslogtreecommitdiffstats
path: root/packages/subproviders/src
diff options
context:
space:
mode:
authorFabio Berger <me@fabioberger.com>2017-12-28 17:28:27 +0800
committerFabio Berger <me@fabioberger.com>2017-12-28 17:28:27 +0800
commitf2976af734a9c9dfdbac16b22040e8bdd97aa426 (patch)
treebbe99ba9dded45c7f7409bff3a13bbf6c30f80b8 /packages/subproviders/src
parentee463058f153fa7de7e7dc9fbe160999cbbb5b11 (diff)
downloaddexon-sol-tools-f2976af734a9c9dfdbac16b22040e8bdd97aa426.tar
dexon-sol-tools-f2976af734a9c9dfdbac16b22040e8bdd97aa426.tar.gz
dexon-sol-tools-f2976af734a9c9dfdbac16b22040e8bdd97aa426.tar.bz2
dexon-sol-tools-f2976af734a9c9dfdbac16b22040e8bdd97aa426.tar.lz
dexon-sol-tools-f2976af734a9c9dfdbac16b22040e8bdd97aa426.tar.xz
dexon-sol-tools-f2976af734a9c9dfdbac16b22040e8bdd97aa426.tar.zst
dexon-sol-tools-f2976af734a9c9dfdbac16b22040e8bdd97aa426.zip
Support both personal_sign and eth_sign
Diffstat (limited to 'packages/subproviders/src')
-rw-r--r--packages/subproviders/src/subproviders/ledger.ts3
1 files changed, 2 insertions, 1 deletions
diff --git a/packages/subproviders/src/subproviders/ledger.ts b/packages/subproviders/src/subproviders/ledger.ts
index 653d0a792..a058e09ad 100644
--- a/packages/subproviders/src/subproviders/ledger.ts
+++ b/packages/subproviders/src/subproviders/ledger.ts
@@ -107,7 +107,8 @@ export class LedgerSubprovider extends Subprovider {
return;
case 'eth_sign':
- const data = payload.params[1];
+ case 'personal_sign':
+ const data = payload.method === 'eth_sign' ? payload.params[1] : payload.params[0];
try {
if (_.isUndefined(data)) {
throw new Error(LedgerSubproviderErrors.DataMissingForSignPersonalMessage);