Skip to content

Commit

Permalink
Emit error if api is not stopped and exit code is greater than zero (e…
Browse files Browse the repository at this point in the history
  • Loading branch information
liza-mae authored and Liza Dayoub committed Aug 22, 2018
1 parent 041cef0 commit 43deaee
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ export function createLocalBrowserDriverApi(log, url, browser) {
});

proc.on('exit', (code) => {
if (!api.isStopped() || code > 0) {
if (!api.isStopped() && code > 0) {
api.emit('error', new Error(driverName + ` exited with code ${code}`));
}
});
Expand Down

0 comments on commit 43deaee

Please sign in to comment.