Skip to content
Permalink
Browse files

fix(grpc): propagate errors in case of timeout

Errors from promiseTimeout are being swallowed by the `catch` handler
and as a result they are not being propagated to the caller. This
prevents our ui from being able to properly react to errros in the
grpc connection process.
  • Loading branch information...
mrfelton committed Aug 14, 2019
1 parent f57f918 commit f109fb2d6bd45de1d3a02cb1e46099972ac80b1a
Showing with 1 addition and 1 deletion.
  1. +1 −1 utils/promiseTimeout.js
@@ -18,5 +18,5 @@ export default function(ms, promise, message = 'Timed out') {
return value
}
// Returns a race between our timeout and the passed in promise
return Promise.race([promise, timeout]).then(clearTimer, clearTimer)
return Promise.race([promise, timeout]).finally(clearTimer)
}

0 comments on commit f109fb2

Please sign in to comment.
You can’t perform that action at this time.