]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - client/src/app/header/search-typeahead.component.ts
Fix lint
[github/Chocobozzz/PeerTube.git] / client / src / app / header / search-typeahead.component.ts
index 396a875c872c0f6f63ae98814887e9ce74b12da0..d0350368dab790bd80ff089e1b84a32ae0b101e4 100644 (file)
@@ -134,7 +134,7 @@ export class SearchTypeaheadComponent implements OnInit, OnDestroy {
     )
   }
 
-  handleKeyUp (event: KeyboardEvent) {
+  handleKey (event: KeyboardEvent) {
     event.stopImmediatePropagation()
     if (!this.keyboardEventsManager) return
 
@@ -143,14 +143,11 @@ export class SearchTypeaheadComponent implements OnInit, OnDestroy {
       case 'ArrowUp':
         this.keyboardEventsManager.onKeydown(event)
         break
-      case 'Enter':
-        this.newSearch = false
-        this.doSearch()
-        break
     }
   }
 
   doSearch () {
+    this.newSearch = false
     const queryParams: Params = {}
 
     if (window.location.pathname === '/search' && this.route.snapshot.queryParams) {