diff --git a/lib/services/search_service.dart b/lib/services/search_service.dart index 219f7584f..af1df223a 100644 --- a/lib/services/search_service.dart +++ b/lib/services/search_service.dart @@ -33,16 +33,6 @@ class SearchService { static final SearchService instance = SearchService._privateConstructor(); Future init() async { - // Intention of delay is to give more CPU cycles to other tasks - // 8 is just a magic number - Future.delayed(const Duration(seconds: 8), () async { - /* In case home screen loads before 8 seconds and user starts search, - future will not be null.So here getAllFiles won't run again in that case. */ - if (_cachedFilesFuture == null) { - _getAllFiles(); - } - }); - Bus.instance.on().listen((event) { // only invalidate, let the load happen on demand _cachedFilesFuture = null;