Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix: get passphrase state error
  • Loading branch information
ByteZhang1024 committed Sep 2, 2025
commit a4bb524e97301af0ffde025425fa66ed75496d9d
6 changes: 3 additions & 3 deletions packages/keyring-eth-onekey/jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,10 @@ module.exports = merge(baseConfig, {
// An object that configures minimum threshold enforcement for coverage results
coverageThreshold: {
global: {
branches: 72.36,
branches: 70.51,
functions: 90.12,
lines: 92.51,
statements: 92.56,
lines: 92.83,
statements: 92.88,
},
},
});
5 changes: 3 additions & 2 deletions packages/keyring-eth-onekey/src/onekey-keyring.ts
Original file line number Diff line number Diff line change
Expand Up @@ -240,8 +240,9 @@ export class OneKeyKeyring extends EventEmitter {
this.passphraseState = passphraseResponse.payload;
}
if (!passphraseResponse.success) {
reject(new Error('getPassphraseState failed'));
return;
throw new Error(
passphraseResponse.payload?.error || 'Unknown error',
);
}
this.passphraseState = passphraseResponse.payload;

Expand Down
Loading