Skip to content

Commit

Permalink
console: fix unlockAccount argument count check (ethereum#21081)
Browse files Browse the repository at this point in the history
  • Loading branch information
fjl authored and enriquefynn committed Feb 15, 2021
1 parent b81b4cd commit 8411e24
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion console/bridge.go
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@ func (b *bridge) readPinAndReopenWallet(call jsre.Call) (goja.Value, error) {
// original RPC method (saved in jeth.unlockAccount) with it to actually execute
// the RPC call.
func (b *bridge) UnlockAccount(call jsre.Call) (goja.Value, error) {
if nArgs := len(call.Arguments); nArgs < 2 {
if len(call.Arguments) < 1 {
return nil, fmt.Errorf("usage: unlockAccount(account, [ password, duration ])")
}
// Make sure we have an account specified to unlock.
Expand Down

0 comments on commit 8411e24

Please sign in to comment.