Skip to content

Commit 9768fb7

Browse files
author
Eugene Terentev
authored
Merge pull request #1 from IvanBinzz/patch-1
Remove last redirect
2 parents b38cadb + d1f3bcd commit 9768fb7

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/handler.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -104,9 +104,11 @@ module.exports = function(options) {
104104
.then((buffer) => { return upload(options.bucket, destKey, buffer, mimeType); })
105105
.then(() => {
106106
fulfill({
107-
statusCode: 301,
107+
isBase64Encoded: true,
108+
statusCode: 200,
109+
body: resizedBuffer.toString('base64'),
108110
headers: {
109-
"Location": options.cdnUrl + '/' + destKey
111+
'Content-Type': mimeType
110112
}
111113
})
112114
})

0 commit comments

Comments
 (0)