Skip to content
This repository has been archived by the owner on Jan 19, 2021. It is now read-only.

Commit

Permalink
Do not abort on uncaught exception
Browse files Browse the repository at this point in the history
The following anywhere in the process will cause magellan to abort and exit:
require('fs').createReadStream( '/tmp/' );

This prevents that.
  • Loading branch information
cahrens777 authored May 29, 2020
1 parent 15f58fc commit 706418e
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions bin/magellan
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,10 @@ const cli = require("../src/cli");
const settings = require("../src/settings");
const constants = require("../src/constants");

process.on('uncaughtException', function (error) {
console.error("Magellan uncaughtException", error);
});

co(function *() {
cli.version();

Expand Down

0 comments on commit 706418e

Please sign in to comment.