mirror of
https://github.com/octoleo/syncthing.git
synced 2025-01-08 17:24:08 +00:00
Merge pull request #1913 from Zillode/fix-reset
Fix 'reset' Rest API on windows
This commit is contained in:
commit
b8b5c5ff34
@ -572,7 +572,12 @@ func (s *apiSvc) postSystemReset(w http.ResponseWriter, r *http.Request) {
|
||||
folder := qs.Get("folder")
|
||||
var err error
|
||||
if len(folder) == 0 {
|
||||
err = resetDB()
|
||||
for folder := range cfg.Folders() {
|
||||
err = s.model.ResetFolder(folder)
|
||||
if err != nil {
|
||||
break
|
||||
}
|
||||
}
|
||||
} else {
|
||||
err = s.model.ResetFolder(folder)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user