diff --git a/src/renderer/components/top-nav/top-nav.js b/src/renderer/components/top-nav/top-nav.js index 27609dc2..ba1eaf58 100644 --- a/src/renderer/components/top-nav/top-nav.js +++ b/src/renderer/components/top-nav/top-nav.js @@ -127,6 +127,12 @@ export default Vue.extend({ ytSuggest(query).then((results) => { this.searchSuggestionsDataList = results this.searchValue = query + }).error((err) => { + console.log(err) + if (this.backendFallback) { + console.log('Error gettings search suggestions. Falling back to Invidious API') + this.getSearchSuggestionsInvidious(query) + } }) }, @@ -148,6 +154,12 @@ export default Vue.extend({ this.$store.dispatch('invidiousAPICall', searchPayload).then((results) => { this.searchSuggestionsDataList = results.suggestions this.searchValue = query + }).error((err) => { + console.log(err) + if (this.backendFallback) { + console.log('Error gettings search suggestions. Falling back to Local API') + this.getSearchSuggestionsLocal(query) + } }) },