Просмотр исходного кода

Don't increment range end when passing to GCS backend

Simon Detheridge 6 лет назад
Родитель
Сommit
5d9f78322d
1 измененных файлов с 0 добавлено и 4 удалено
  1. 0 4
      services/filestore/app/js/GcsPersistor.js

+ 0 - 4
services/filestore/app/js/GcsPersistor.js

@@ -115,10 +115,6 @@ async function sendStream(bucketName, key, readStream, sourceMd5) {
 
 
 async function getFileStream(bucketName, key, _opts = {}) {
 async function getFileStream(bucketName, key, _opts = {}) {
   const opts = Object.assign({}, _opts)
   const opts = Object.assign({}, _opts)
-  if (opts.end) {
-    // S3 (and http range headers) treat 'end' as inclusive, so increase this by 1
-    opts.end++
-  }
   const stream = storage
   const stream = storage
     .bucket(bucketName)
     .bucket(bucketName)
     .file(key)
     .file(key)