Skip to content

Fix: Do not load non-library files

Martin Hoeher requested to merge 378-endless-sync-loop into master

This fixes a bug which could be triggered e.g. when recovering items from a cloud platform. The app would potentially load the same item file multiple times (i.e. "{xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx}.otl" and "{xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx} (restored).otl" (could be created e.g. by NextCloud). This would then cause two writes in the scanning phase, which in turn triggeres the cache to emit the libraryChanged signal which in turn causes another sync which closes the circle.

This is fixed by having a very strict check on the file name of items, which must match exactly the pattern GUID (as string) + ".otl".

Closes #378 (closed)

Merge request reports