diff options
author | Chocobozzz <me@florianbigard.com> | 2021-12-15 15:58:10 +0100 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2021-12-16 10:08:55 +0100 |
commit | a9bfa85d2cdf13670aaced740da5b493fbeddfce (patch) | |
tree | 3781c9218d4cc7786b6589365c0efbed2151703d /client/src/app/shared/shared-search | |
parent | c77fdc605b3ccc1ab6890f889d8200fbe9372949 (diff) | |
download | PeerTube-a9bfa85d2cdf13670aaced740da5b493fbeddfce.tar.gz PeerTube-a9bfa85d2cdf13670aaced740da5b493fbeddfce.tar.zst PeerTube-a9bfa85d2cdf13670aaced740da5b493fbeddfce.zip |
Add ability for admins to set default p2p policy
Diffstat (limited to 'client/src/app/shared/shared-search')
-rw-r--r-- | client/src/app/shared/shared-search/search.service.ts | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/client/src/app/shared/shared-search/search.service.ts b/client/src/app/shared/shared-search/search.service.ts index 61acfb466..ad2de0f37 100644 --- a/client/src/app/shared/shared-search/search.service.ts +++ b/client/src/app/shared/shared-search/search.service.ts | |||
@@ -4,7 +4,6 @@ import { HttpClient, HttpParams } from '@angular/common/http' | |||
4 | import { Injectable } from '@angular/core' | 4 | import { Injectable } from '@angular/core' |
5 | import { ComponentPaginationLight, RestExtractor, RestPagination, RestService } from '@app/core' | 5 | import { ComponentPaginationLight, RestExtractor, RestPagination, RestService } from '@app/core' |
6 | import { Video, VideoChannel, VideoChannelService, VideoService } from '@app/shared/shared-main' | 6 | import { Video, VideoChannel, VideoChannelService, VideoService } from '@app/shared/shared-main' |
7 | import { peertubeLocalStorage } from '@root-helpers/peertube-web-storage' | ||
8 | import { | 7 | import { |
9 | ResultList, | 8 | ResultList, |
10 | Video as VideoServerModel, | 9 | Video as VideoServerModel, |
@@ -25,11 +24,7 @@ export class SearchService { | |||
25 | private restService: RestService, | 24 | private restService: RestService, |
26 | private videoService: VideoService, | 25 | private videoService: VideoService, |
27 | private playlistService: VideoPlaylistService | 26 | private playlistService: VideoPlaylistService |
28 | ) { | 27 | ) { } |
29 | // Add ability to override search endpoint if the user updated this local storage key | ||
30 | const searchUrl = peertubeLocalStorage.getItem('search-url') | ||
31 | if (searchUrl) SearchService.BASE_SEARCH_URL = searchUrl | ||
32 | } | ||
33 | 28 | ||
34 | searchVideos (parameters: { | 29 | searchVideos (parameters: { |
35 | search?: string | 30 | search?: string |