Stop Baloo backend from failing when Baloo indexes non-existing folder
Reason for the change
Currently:
-
The Baloo backend does not get activated when Baloo is told to index a non-existing directory.
-
The Baloo backend does not get activated when Baloo is set to index a sub-directory of a directory that is explicitly set to not be indexed.
-
The Baloo indexer is activated when Baloo is set to not index a sub-directory of a music source. For example, if we set
/home/music
as a source, and tell Baloo to stop indexing/home/music/album
then Elisa will not find any files in this directory.. If the Baloo backend is disabled (from the config dialogue) then Elisa does find the files.
This MR fixes all of these issues.
Test plan
Test 1
- Make a folder
~/elisatest1
and tell Baloo to not index it - Delete the folder
~/elisatest1
- Start Elisa
Before:
- The Baloo backend for Elisa would not be activated
Now:
- The Baloo backend for Elisa is activated
Test 2
- Make the folder
~/elisatest2
and tell Baloo to not index it - Make a sub folder
~/elisatest2/music
and tell Baloo to index it - Tell Elisa to use
~/elisatest2/music
as a music source
Before:
- The Baloo backend for Elisa would not be activated
Now:
- The Baloo backend for Elisa works is activated
Test 3
- Tell Baloo to index
~/elisatest3
and tell Baloo to stop indexing it - Make the sub-folder
~/elisatest3/music
and place a music file in it - Tell Elisa to use
~/elisatest3
as a source
Before:
- The Baloo backend for Elisa is activated
- Elisa does not find the file in
~/elisatest3/music
Now:
- The Baloo backend for Elisa is not activated
- Elisa finds the file in
~/elisatest3/music
Edited by Jack Hill