mirror of
https://github.com/TeamPiped/Piped.git
synced 2024-08-14 23:57:27 +00:00
Ensure saved search history does not appear when disabled.
This commit is contained in:
parent
f920a1aae8
commit
5af767decb
1 changed files with 2 additions and 1 deletions
|
@ -48,7 +48,8 @@ export default {
|
||||||
},
|
},
|
||||||
async refreshSuggestions() {
|
async refreshSuggestions() {
|
||||||
if (!this.searchText) {
|
if (!this.searchText) {
|
||||||
this.searchSuggestions = JSON.parse(localStorage.getItem("search_history")) ?? [];
|
if (this.getPreferenceBoolean("searchHistory", false))
|
||||||
|
this.searchSuggestions = JSON.parse(localStorage.getItem("search_history")) ?? [];
|
||||||
} else {
|
} else {
|
||||||
this.searchSuggestions = (
|
this.searchSuggestions = (
|
||||||
await this.fetchJson(this.apiUrl() + "/opensearch/suggestions", {
|
await this.fetchJson(this.apiUrl() + "/opensearch/suggestions", {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue