Explorar o código

fix: stop search loading when exiting

NGPixel %!s(int64=5) %!d(string=hai) anos
pai
achega
144950ea70
Modificáronse 1 ficheiros con 2 adicións e 1 borrados
  1. 2 1
      client/components/common/search-results.vue

+ 2 - 1
client/components/common/search-results.vue

@@ -100,9 +100,10 @@ export default {
   watch: {
     search(newValue, oldValue) {
       this.cursor = 0
-      if (newValue && newValue.length < 2) {
+      if (!newValue || (newValue && newValue.length < 2)) {
         this.response.results = []
         this.response.suggestions = []
+        this.searchIsLoading = false
       } else {
         this.searchIsLoading = true
       }