mirror of https://github.com/Chocobozzz/PeerTube
Reset search on page change
parent
14122085ec
commit
ff644b3066
|
@ -18,10 +18,9 @@ export class HeaderComponent implements OnInit {
|
||||||
this.router.events
|
this.router.events
|
||||||
.pipe(
|
.pipe(
|
||||||
filter(e => e instanceof NavigationEnd),
|
filter(e => e instanceof NavigationEnd),
|
||||||
map(() => getParameterByName('search', window.location.href)),
|
map(() => getParameterByName('search', window.location.href))
|
||||||
filter(searchQuery => !!searchQuery)
|
|
||||||
)
|
)
|
||||||
.subscribe(searchQuery => this.searchValue = searchQuery)
|
.subscribe(searchQuery => this.searchValue = searchQuery || '')
|
||||||
}
|
}
|
||||||
|
|
||||||
doSearch () {
|
doSearch () {
|
||||||
|
|
Loading…
Reference in New Issue