flounder

A simple gemini site builder
Log | Files | Refs | README | LICENSE

commit 73cee727f63bc89ce49772003f5a61a79f98af8d
parent 9d08acc9a00f80cfbbc0145ddf0608a00593770e
Author: alex wennerberg <alex@alexwennerberg.com>
Date:   Wed, 18 Nov 2020 19:03:51 -0800

tmpfix

Diffstat:
Mmain.go | 5+++--
1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/main.go b/main.go @@ -85,12 +85,13 @@ func getUsers() ([]User, error) { // NOTE -- dont use on unsafe input ( I think ) func getLocalPath(filesPath string) string { l := len(strings.Split(c.FilesDirectory, "/")) - return strings.Join(strings.Split(filesPath, "/")[l:], "/") + return strings.Join(strings.Split(filesPath, "/")[l+1:], "/") } func getCreator(filePath string) string { l := len(strings.Split(c.FilesDirectory, "/")) - r := strings.Split(filePath, "/")[l-1] + r := strings.Split(filePath, "/")[l] + fmt.Println(filePath, c.FilesDirectory, r) return r }