mirror of https://github.com/Chocobozzz/PeerTube
parent
c9b369096d
commit
fb7b009d63
|
@ -363,7 +363,7 @@ export abstract class AbstractVideoList implements OnInit, OnDestroy, AfterConte
|
|||
categoryOneOf: this.categoryOneOf
|
||||
}
|
||||
|
||||
let path = this.router.url
|
||||
let path = this.getUrlWithoutParams()
|
||||
if (!path || path === '/') path = this.serverConfig.instance.defaultClientRoute
|
||||
|
||||
this.router.navigate([ path ], { queryParams, replaceUrl: true, queryParamsHandling: 'merge' })
|
||||
|
@ -380,4 +380,10 @@ export abstract class AbstractVideoList implements OnInit, OnDestroy, AfterConte
|
|||
this.nsfwPolicy = user.nsfwPolicy
|
||||
}))
|
||||
}
|
||||
|
||||
private getUrlWithoutParams () {
|
||||
let urlTree = this.router.parseUrl(this.router.url)
|
||||
urlTree.queryParams = {}
|
||||
return urlTree.toString()
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue