diff --git a/lib/image-stream/handlers.js b/lib/image-stream/handlers.js index aa844034..04f1c527 100644 --- a/lib/image-stream/handlers.js +++ b/lib/image-stream/handlers.js @@ -54,7 +54,7 @@ module.exports = { * @returns {Promise} */ 'application/x-bzip2': (imagePath, options) => { - return Bluebird.props({ + return { path: imagePath, archiveExtension: fileExtensions.getLastFileExtension(imagePath), extension: fileExtensions.getPenultimateFileExtension(imagePath), @@ -67,7 +67,7 @@ module.exports = { } }, transform: unbzip2Stream() - }) + } }, /** @@ -94,7 +94,7 @@ module.exports = { } }) }).then((uncompressedSize) => { - return Bluebird.props({ + return { path: imagePath, archiveExtension: fileExtensions.getLastFileExtension(imagePath), extension: fileExtensions.getPenultimateFileExtension(imagePath), @@ -107,7 +107,7 @@ module.exports = { } }, transform: zlib.createGunzip() - }) + } }) }, @@ -223,7 +223,7 @@ module.exports = { * @returns {Promise} */ 'application/octet-stream': (imagePath, options) => { - return Bluebird.props({ + return { path: imagePath, extension: fileExtensions.getLastFileExtension(imagePath), stream: fs.createReadStream(imagePath), @@ -235,7 +235,7 @@ module.exports = { } }, transform: new PassThroughStream() - }) + } } }