Skip to content

Commit

Permalink
fix(api-gateway): getTime on undefined call in case of web socket aut…
Browse files Browse the repository at this point in the history
…h error
  • Loading branch information
paveltiunov committed Dec 10, 2019
1 parent 90a7472 commit 9807b1e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/cubejs-api-gateway/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,7 @@ class ApiGateway {
}

duration(requestStarted) {
return new Date().getTime() - requestStarted.getTime();
return requestStarted && (new Date().getTime() - requestStarted.getTime());
}

async meta({ context, res }) {
Expand Down

0 comments on commit 9807b1e

Please sign in to comment.