Fix decaf error in FSPersistorManager

This commit is contained in:
Simon Detheridge 2019-12-16 11:16:37 +00:00
parent 0b6e725137
commit e06c03e536

View file

@ -82,11 +82,11 @@ module.exports = {
{ err, location, filteredName: name }, { err, location, filteredName: name },
'Error reading from file' 'Error reading from file'
) )
} if (err.code === 'ENOENT') {
if (err.code === 'ENOENT') { return callback(new Errors.NotFoundError(err.message), null)
return callback(new Errors.NotFoundError(err.message), null) } else {
} else { return callback(err, null)
return callback(err, null) }
} }
opts.fd = fd opts.fd = fd
const sourceStream = fs.createReadStream(null, opts) const sourceStream = fs.createReadStream(null, opts)