Document reasoning on error silencing

This commit is contained in:
Mariusz Nowak 2019-09-27 12:04:22 +02:00
parent f67ca3901d
commit a3933eaf40
No known key found for this signature in database
GPG Key ID: B1FBDA8A182B03F2

View File

@ -27,5 +27,8 @@ try {
.then(() => serverless.utils.logStat(serverless, 'install'))
.catch(() => {});
} catch (error) {
// fail silently
// Ignore any eventual errors.
// Package when installed globally may be installed in uncommon user contexts,
// that may lead to fs access related crashes
// when e.g. trying to access user's .serverlessrc config
}