From 8d9c10bc51d5200175811408578b826fd2cb00bf Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Mon, 31 Jan 2022 11:15:44 +0100 Subject: Limit scope to local when finding in bulk --- .../shared/shared-search/find-in-bulk.service.ts | 23 +++++++++++++++++++--- 1 file changed, 20 insertions(+), 3 deletions(-) (limited to 'client') diff --git a/client/src/app/shared/shared-search/find-in-bulk.service.ts b/client/src/app/shared/shared-search/find-in-bulk.service.ts index 8ca64c37e..117685cc6 100644 --- a/client/src/app/shared/shared-search/find-in-bulk.service.ts +++ b/client/src/app/shared/shared-search/find-in-bulk.service.ts @@ -7,6 +7,7 @@ import { ResultList } from '@shared/models/common' import { Video, VideoChannel } from '../shared-main' import { VideoPlaylist } from '../shared-video-playlist' import { SearchService } from './search.service' +import { AdvancedSearch } from './advanced-search.model' const logger = debug('peertube:search:FindInBulkService') @@ -18,6 +19,8 @@ type BulkObservables

= { @Injectable() export class FindInBulkService { + private advancedSearchForBulk: AdvancedSearch + private getVideoInBulk: BulkObservables> private getChannelInBulk: BulkObservables> private getPlaylistInBulk: BulkObservables> @@ -28,6 +31,8 @@ export class FindInBulkService { this.getVideoInBulk = this.buildBulkObservableObject(this.getVideosInBulk.bind(this)) this.getChannelInBulk = this.buildBulkObservableObject(this.getChannelsInBulk.bind(this)) this.getPlaylistInBulk = this.buildBulkObservableObject(this.getPlaylistsInBulk.bind(this)) + + this.advancedSearchForBulk = new AdvancedSearch({ searchTarget: 'local' }) } getVideo (uuid: string): Observable

(bulkGet: (params: P[]) => Observable) { -- cgit v1.2.3