aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/screens/search/SearchScreen.tsx11
1 files changed, 2 insertions, 9 deletions
diff --git a/src/screens/search/SearchScreen.tsx b/src/screens/search/SearchScreen.tsx
index 4e6ce6a4..90501734 100644
--- a/src/screens/search/SearchScreen.tsx
+++ b/src/screens/search/SearchScreen.tsx
@@ -54,13 +54,6 @@ const SearchScreen: React.FC = () => {
const dispatch = useDispatch();
/*
- * If user begins actively searching, refresh recently-searched list.
- */
- useEffect(() => {
- if (searching) loadRecentSearches();
- }, [searching]);
-
- /*
* Main handler for changes in query.
*/
useEffect(() => {
@@ -106,11 +99,11 @@ const SearchScreen: React.FC = () => {
// when searching state changes, run animation and reset query accordingly
useEffect(() => {
if (searching) {
- timing(top, topInConfig).start(() => setResults(undefined));
+ timing(top, topInConfig).start();
} else {
setQuery('');
handleBlur();
- timing(top, topOutConfig).start();
+ timing(top, topOutConfig).start(() => setResults(undefined));
}
}, [searching]);