Skip to content

Commit

Permalink
v3rpc: add ErrNoLeader to 'togRPCError'
Browse files Browse the repository at this point in the history
  • Loading branch information
gyuho committed Nov 2, 2016
1 parent e5dd5d6 commit 6f6d627
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion etcdserver/api/v3rpc/util.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ func togRPCError(err error) error {
case etcdserver.ErrTooManyRequests:
return rpctypes.ErrTooManyRequests

case etcdserver.ErrNoLeader:
case etcdserver.ErrNoLeader, rpctypes.ErrNoLeader: // ErrNoLeader from leasehttp
return rpctypes.ErrGRPCNoLeader
case etcdserver.ErrStopped:
return rpctypes.ErrGRPCStopped
Expand Down

0 comments on commit 6f6d627

Please sign in to comment.