mirror of
https://github.com/drakkan/sftpgo.git
synced 2025-12-07 23:00:55 +03:00
webclient: fix link for shares with a trailing space
Signed-off-by: Nicola Murino <nicola.murino@gmail.com>
This commit is contained in:
@@ -1503,8 +1503,7 @@ func getShareFromPostFields(r *http.Request) (*dataprovider.Share, error) {
|
||||
share.Name = strings.TrimSpace(r.Form.Get("name"))
|
||||
share.Description = r.Form.Get("description")
|
||||
for _, p := range r.Form["paths"] {
|
||||
p = strings.TrimSpace(p)
|
||||
if p != "" {
|
||||
if strings.TrimSpace(p) != "" {
|
||||
share.Paths = append(share.Paths, p)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user