Add files via upload

This commit is contained in:
niubility000 2021-12-16 11:53:06 +08:00 committed by GitHub
parent a078f0b787
commit 4a5f8a017d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -7,7 +7,7 @@ import (
"fmt"
"io"
"net/http"
"path/filepath"
"github.com/gorilla/mux"
"github.com/filebrowser/filebrowser/v2/files"
@ -152,5 +152,6 @@ func createPreview(imgSvc ImgService, fileCache FileCache,
}
func previewCacheKey(fPath string, fTime int64, previewSize PreviewSize) string {
fPath = filepath.Base(fPath)
return fmt.Sprintf("%x%x%x", fPath, fTime, previewSize)
}