1
0
mirror of https://github.com/nxshock/gallery.git synced 2024-11-27 00:11:00 +05:00

Fix links to files and preview images

This commit is contained in:
nxshock 2023-04-09 21:48:40 +05:00
parent 378a467f65
commit 41d00de7b7

View File

@ -15,7 +15,7 @@ func getResponse(path string) ([]Item, error) {
} }
for i := range fileNames { for i := range fileNames {
fileNames[i] = strings.TrimPrefix(filepath.ToSlash(fileNames[i]), filepath.ToSlash(config.WorkingDirectory)) fileNames[i] = strings.TrimPrefix(filepath.ToSlash(fileNames[i]), filepath.ToSlash(config.WorkingDirectory))[1:] // TODO: check is first slash properly removed
} }
items := make([]Item, 0) items := make([]Item, 0)