1
0
Fork 0

do not print errors on shutdown

This commit is contained in:
jsteemann 2017-05-09 10:26:59 +02:00
parent 51b5dbbe57
commit d0ae7673b9
1 changed files with 4 additions and 1 deletions

View File

@ -486,7 +486,10 @@ exports.historian = function () {
}
}
} catch (err) {
require('console').warn('catch error in historian: %s', err.stack);
// errors on shutdown are expected. do not log them in case they occur
if (err.errorNum !== internal.errors.ERROR_SHUTTING_DOWN.code) {
require('console').warn('catch error in historian: %s', err.stack);
}
}
};