diff --git a/internal/config/config.go b/internal/config/config.go index 52d890876..b796b8e94 100644 --- a/internal/config/config.go +++ b/internal/config/config.go @@ -26,6 +26,7 @@ import ( "reflect" "sort" "strconv" + "strings" "github.com/calmh/logger" "github.com/syncthing/protocol" @@ -261,6 +262,10 @@ func (cfg *Configuration) prepare(myID protocol.DeviceID) { continue } + if !strings.HasSuffix(folder.Path, string(filepath.Separator)) { + folder.Path += string(filepath.Separator) + } + if folder.ID == "" { folder.ID = "default" }