]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - shared/extra-utils/requests/check-api-params.ts
Optimize torrent URL update
[github/Chocobozzz/PeerTube.git] / shared / extra-utils / requests / check-api-params.ts
index 7df63b0044c0a4a2141c90f47364f0befef97fb3..26ba1e9132eb6ec783d6e61ad5b59832e85ffd8b 100644 (file)
@@ -1,4 +1,4 @@
-import { HttpStatusCode } from '@shared/core-utils'
+import { HttpStatusCode } from '@shared/models'
 import { makeGetRequest } from './requests'
 
 function checkBadStartPagination (url: string, path: string, token?: string, query = {}) {
@@ -7,7 +7,7 @@ function checkBadStartPagination (url: string, path: string, token?: string, que
     path,
     token,
     query: { ...query, start: 'hello' },
-    statusCodeExpected: HttpStatusCode.BAD_REQUEST_400
+    expectedStatus: HttpStatusCode.BAD_REQUEST_400
   })
 }
 
@@ -17,7 +17,7 @@ async function checkBadCountPagination (url: string, path: string, token?: strin
     path,
     token,
     query: { ...query, count: 'hello' },
-    statusCodeExpected: HttpStatusCode.BAD_REQUEST_400
+    expectedStatus: HttpStatusCode.BAD_REQUEST_400
   })
 
   await makeGetRequest({
@@ -25,7 +25,7 @@ async function checkBadCountPagination (url: string, path: string, token?: strin
     path,
     token,
     query: { ...query, count: 2000 },
-    statusCodeExpected: HttpStatusCode.BAD_REQUEST_400
+    expectedStatus: HttpStatusCode.BAD_REQUEST_400
   })
 }
 
@@ -35,7 +35,7 @@ function checkBadSortPagination (url: string, path: string, token?: string, quer
     path,
     token,
     query: { ...query, sort: 'hello' },
-    statusCodeExpected: HttpStatusCode.BAD_REQUEST_400
+    expectedStatus: HttpStatusCode.BAD_REQUEST_400
   })
 }