Skip to content

Commit 66b50b5

Browse files
committed
1 parent 8c7208a commit 66b50b5

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

oauth2.go

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -270,7 +270,10 @@ func (c *Config) Poll(ctx context.Context, da *DeviceAuthResponse, opts ...AuthC
270270
return tok, nil
271271
}
272272

273-
e, _ := err.(*RetrieveError)
273+
e, ok := err.(*RetrieveError)
274+
if !ok {
275+
return nil, err
276+
}
274277
switch e.ErrorCode {
275278
case errSlowDown:
276279
interval += 5

0 commit comments

Comments
 (0)