Prevents the app from checking every desktop file in the system. (cherry picked from commit 20becd46)