From 4be56136e19b3b5f4d8fea26283d8e83b7d84a9e Mon Sep 17 00:00:00 2001 From: Yen Truong <36055303+yen-tt@users.noreply.github.com> Date: Mon, 14 Feb 2022 15:09:35 -0500 Subject: [PATCH] Revert "allow search to occur if "near me" request fails (#1668)" This reverts commit 81fe3076c4e36799d02d0300838929dd77fcdddc. --- src/ui/components/search/searchcomponent.js | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/ui/components/search/searchcomponent.js b/src/ui/components/search/searchcomponent.js index 126464110..e4432316f 100644 --- a/src/ui/components/search/searchcomponent.js +++ b/src/ui/components/search/searchcomponent.js @@ -581,10 +581,7 @@ export default class SearchComponent extends Component { promptForLocation (query) { if (this._promptForLocation) { return this.fetchQueryIntents(query) - .then( - queryIntents => queryIntents.includes('NEAR_ME'), - error => Promise.reject(new Error('Failed to fetch query intents.', { cause: error })) - ) + .then(queryIntents => queryIntents.includes('NEAR_ME')) .then(queryHasNearMeIntent => { if (queryHasNearMeIntent && !this.core.storage.get(StorageKeys.GEOLOCATION)) { return new Promise((resolve, reject) => @@ -607,8 +604,7 @@ export default class SearchComponent extends Component { this._geolocationOptions) ); } - }) - .catch(error => console.warn('Unable to determine user\'s location.', error)); + }); } else { return Promise.resolve(); }