check if listened before adding queries
This commit is contained in:
1 parent
81f04c2078
commit
bb77f8c015
7 files changed
+45
-27
No files matched your search
@@ -62,9 +62,11 @@ class SiteSearch extends HookConsumerWidget {
|
||||
final searchFocusNode = useFocusNode();
|
||||
|
||||
useListenableCallback(searchTextController, () {
|
||||
ref
|
||||
.read(searchSuggestionsProvider().notifier)
|
||||
.addQuery(searchTextController.text);
|
||||
if (ref.exists(searchSuggestionsProvider())) {
|
||||
ref
|
||||
.read(searchSuggestionsProvider().notifier)
|
||||
.addQuery(searchTextController.text);
|
||||
}
|
||||
});
|
||||
|
||||
final selectedBang = ref.watch(selectedBangDataProvider(domain: domain));
|
||||
|
||||
Reference in new issue
Block a user