Co-authored-by: Orca <help@stably.ai>
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
import { Buffer } from 'node:buffer'
|
||||
import type { AzureDevOpsRepoRef } from './repository-ref'
|
||||
import { cancelUnreadResponseBody } from '../lib/unread-response-body'
|
||||
import { readFetchResponseJsonWithinLimit } from '../lib/fetch-response-body'
|
||||
|
||||
const REQUEST_TIMEOUT_MS = 5000
|
||||
|
||||
@@ -96,7 +95,7 @@ export async function requestAzureDevOpsJsonAtBase<T>(
|
||||
}
|
||||
return null
|
||||
}
|
||||
return await readFetchResponseJsonWithinLimit<T>(response)
|
||||
return (await response.json()) as T
|
||||
} catch (error) {
|
||||
if (throwOnFailure) {
|
||||
throw error
|
||||
|
||||
Reference in New Issue
Block a user