瀏覽代碼

gdrive: add mime-type correctly

pull/294/head
Stefan Benten 4 年之前
父節點
當前提交
d3af6ad6e8
共有 1 個檔案被更改,包括 2 行新增2 行删除
  1. +2
    -2
      server/storage/gdrive.go

+ 2
- 2
server/storage/gdrive.go 查看文件

@@ -95,7 +95,7 @@ func (s *GDrive) Get(token string, filename string) (reader io.ReadCloser, metad
}

metadata = Metadata{
ContentType: "",
ContentType: fi.MimeType,
ContentLength: fi.Size,
Downloads: downloads,
MaxDownloads: maxdownloads,
@@ -142,7 +142,7 @@ func (s *GDrive) Head(token string, filename string) (metadata Metadata, err err
}

metadata = Metadata{
ContentType: "",
ContentType: fi.MimeType,
ContentLength: fi.Size,
Downloads: downloads,
MaxDownloads: maxdownloads,


Loading…
取消
儲存