]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - client/src/app/search/advanced-search.model.ts
Properly scroll to anchors in links, especially in admin config
[github/Chocobozzz/PeerTube.git] / client / src / app / search / advanced-search.model.ts
index e2a0253f44bb98c4a117005ffd6d9fac4254282b..50f00bc2713183449443d497abe421982751217b 100644 (file)
@@ -65,7 +65,7 @@ export class AdvancedSearch {
     for (const k of Object.keys(obj)) {
       if (k === 'sort') continue // Exception
 
-      if (obj[k] !== undefined) return true
+      if (obj[k] !== undefined && obj[k] !== '') return true
     }
 
     return false
@@ -131,7 +131,7 @@ export class AdvancedSearch {
     for (const k of Object.keys(obj)) {
       if (k === 'sort') continue // Exception
 
-      if (obj[k] !== undefined) acc++
+      if (obj[k] !== undefined && obj[k] !== '') acc++
     }
 
     return acc