aboutsummaryrefslogtreecommitdiffhomepage
path: root/shared/extra-utils/server
diff options
context:
space:
mode:
Diffstat (limited to 'shared/extra-utils/server')
-rw-r--r--shared/extra-utils/server/follows.ts11
1 files changed, 7 insertions, 4 deletions
diff --git a/shared/extra-utils/server/follows.ts b/shared/extra-utils/server/follows.ts
index 0379bb109..365263a22 100644
--- a/shared/extra-utils/server/follows.ts
+++ b/shared/extra-utils/server/follows.ts
@@ -2,15 +2,17 @@ import * as request from 'supertest'
2import { ServerInfo } from './servers' 2import { ServerInfo } from './servers'
3import { waitJobs } from './jobs' 3import { waitJobs } from './jobs'
4import { makePostBodyRequest } from '../requests/requests' 4import { makePostBodyRequest } from '../requests/requests'
5import { FollowState } from '@shared/models'
5 6
6function getFollowersListPaginationAndSort (url: string, start: number, count: number, sort: string, search?: string) { 7function getFollowersListPaginationAndSort (url: string, start: number, count: number, sort: string, search?: string, state?: FollowState) {
7 const path = '/api/v1/server/followers' 8 const path = '/api/v1/server/followers'
8 9
9 const query = { 10 const query = {
10 start, 11 start,
11 count, 12 count,
12 sort, 13 sort,
13 search 14 search,
15 state
14 } 16 }
15 17
16 return request(url) 18 return request(url)
@@ -43,14 +45,15 @@ function rejectFollower (url: string, token: string, follower: string, statusCod
43 }) 45 })
44} 46}
45 47
46function getFollowingListPaginationAndSort (url: string, start: number, count: number, sort: string, search?: string) { 48function getFollowingListPaginationAndSort (url: string, start: number, count: number, sort: string, search?: string, state?: FollowState) {
47 const path = '/api/v1/server/following' 49 const path = '/api/v1/server/following'
48 50
49 const query = { 51 const query = {
50 start, 52 start,
51 count, 53 count,
52 sort, 54 sort,
53 search 55 search,
56 state
54 } 57 }
55 58
56 return request(url) 59 return request(url)