feat: small fix

License: MIT
Signed-off-by: Henrique Dias <hacdias@gmail.com>
This commit is contained in:
Henrique Dias 2019-01-01 23:09:48 +00:00
parent 3c8d78189d
commit e0cf46083b
2 changed files with 3 additions and 3 deletions

@ -1 +1 @@
Subproject commit a9852a50b409c7c2d57663e6cf53e0980eee87b3 Subproject commit 73080fb56d24a57005d8c4e415249693aa615aca

View File

@ -4,12 +4,12 @@ import (
"crypto/rand" "crypto/rand"
"encoding/base64" "encoding/base64"
"net/http" "net/http"
"path/filepath"
"strconv" "strconv"
"strings" "strings"
"time" "time"
"github.com/filebrowser/filebrowser/types" "github.com/filebrowser/filebrowser/types"
"github.com/spf13/afero"
) )
const apiSharePrefix = "/api/share" const apiSharePrefix = "/api/share"
@ -25,7 +25,7 @@ func (e *Env) getShareData(w http.ResponseWriter, r *http.Request, prefix string
return "", false return "", false
} }
return filepath.Join(user.Scope, relPath), ok return afero.FullBaseFsPath(user.Fs.(*afero.BasePathFs), relPath), ok
} }
func (e *Env) shareGetHandler(w http.ResponseWriter, r *http.Request) { func (e *Env) shareGetHandler(w http.ResponseWriter, r *http.Request) {