diff --git a/index.js b/index.js index 8da4625..672294b 100644 --- a/index.js +++ b/index.js @@ -23,7 +23,7 @@ module.exports = function (qiniu, option) { return through2.obj(function (file, enc, next) { var that = this; var isIgnore = false; - var filePath = path.relative(file.base, file.path); + var filePath = path.relative(file.base, file.path).split(path.sep).join('/'); if (file._contents === null) return next(); option.ignore.forEach(function(item) {