Fix bug where file upload location was not respected.

This commit is contained in:
Gabriel Simmer 2019-02-24 14:53:55 -08:00
parent bd6b7c86b2
commit 8b49d75077
No known key found for this signature in database
GPG key ID: 0394452F45EF2817

View file

@ -144,7 +144,7 @@ func UploadFile() common.Handler {
}
defer file.Close()
f, err := os.OpenFile(storage+path+handler.Filename, os.O_WRONLY|os.O_CREATE, 0666)
f, err := os.OpenFile(storage+"/"+path+"/"+handler.Filename, os.O_WRONLY|os.O_CREATE, 0666)
if err != nil {
panic(err)