aboutsummaryrefslogtreecommitdiffhomepage
path: root/shared/extra-utils
diff options
context:
space:
mode:
Diffstat (limited to 'shared/extra-utils')
-rw-r--r--shared/extra-utils/search/video-channels.ts15
1 files changed, 14 insertions, 1 deletions
diff --git a/shared/extra-utils/search/video-channels.ts b/shared/extra-utils/search/video-channels.ts
index 0532134ae..d16210530 100644
--- a/shared/extra-utils/search/video-channels.ts
+++ b/shared/extra-utils/search/video-channels.ts
@@ -1,3 +1,4 @@
1import { VideoChannelsSearchQuery } from '@shared/models'
1import { makeGetRequest } from '../requests/requests' 2import { makeGetRequest } from '../requests/requests'
2 3
3function searchVideoChannel (url: string, search: string, token?: string, statusCodeExpected = 200) { 4function searchVideoChannel (url: string, search: string, token?: string, statusCodeExpected = 200) {
@@ -15,8 +16,20 @@ function searchVideoChannel (url: string, search: string, token?: string, status
15 }) 16 })
16} 17}
17 18
19function advancedVideoChannelSearch (url: string, search: VideoChannelsSearchQuery) {
20 const path = '/api/v1/search/video-channels'
21
22 return makeGetRequest({
23 url,
24 path,
25 query: search,
26 statusCodeExpected: 200
27 })
28}
29
18// --------------------------------------------------------------------------- 30// ---------------------------------------------------------------------------
19 31
20export { 32export {
21 searchVideoChannel 33 searchVideoChannel,
34 advancedVideoChannelSearch
22} 35}