Skip to content

Commit 23bb2eb

Browse files
committed
Merge pull request nitaigao#6 from And-re/patch-1
replace backslashes in uploadPath
2 parents af55865 + 70b7204 commit 23bb2eb

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

index.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ module.exports = function (aws, options) {
1818
if (!isFile) { return false; }
1919

2020
var uploadPath = file.path.replace(file.base, options.uploadPath || '');
21+
uploadPath = uploadPath.replace(new RegExp('\\\\', 'g'), '/');
2122
var headers = { 'x-amz-acl': 'public-read' };
2223
if (options.headers) {
2324
for (var key in options.headers) {

0 commit comments

Comments
 (0)