lib/model: Check folder error before sync-waiting (fixes #6793) (#6847)

This commit is contained in:
Simon Frei
2020-07-31 19:26:09 +02:00
committed by GitHub
parent 850dd4cd25
commit a85bc1c3a6
2 changed files with 23 additions and 15 deletions
-14
View File
@@ -166,20 +166,6 @@ func newSendReceiveFolder(model *model, fset *db.FileSet, ignores *ignore.Matche
// pull returns true if it manages to get all needed items from peers, i.e. get
// the device in sync with the global state.
func (f *sendReceiveFolder) pull() bool {
// Check if the ignore patterns changed.
oldHash := f.ignores.Hash()
defer func() {
if f.ignores.Hash() != oldHash {
f.ignoresUpdated()
}
}()
err := f.getHealthErrorAndLoadIgnores()
f.setError(err)
if err != nil {
l.Debugln("Skipping pull of", f.Description(), "due to folder error:", err)
return false
}
l.Debugf("%v pulling", f)
scanChan := make(chan string)