I found this in some code. Is there ever a good reason to do this?
}).catch(() => {
resolve();
});
I'm curious about whether there are any conceivable ways that this is a good thing to do, but in this case the code I'm reviewing is:
function checkExtendedPackage(config, packagePath) {
return new Promise((resolve, reject) => {
extend.check(packagePath)
.then(() => {
extend.validate(packagePath, config.allowExtends, config.scope)
.then(packageToExtend => {
showOutput.log([{
type: 'success',
description: 'validating',
message: packageToExtend
}]);
resolve();
}).catch(err => {
reject(err);
});
}).catch(() => {
resolve();
});
});
}