修复旧版请求函数中的重定向选项
This commit is contained in:
@@ -206,6 +206,8 @@ export const request = async <T = unknown>(url: string, options: Options = {}):
|
|||||||
body,
|
body,
|
||||||
signal: options.signal,
|
signal: options.signal,
|
||||||
dispatcher: buildRequestDispatcher(options),
|
dispatcher: buildRequestDispatcher(options),
|
||||||
|
// @ts-expect-error
|
||||||
|
maxRedirections: options.maxRedirect ?? defaultOptions.maxRedirect,
|
||||||
}).then(async(response) => {
|
}).then(async(response) => {
|
||||||
if (options.needBody) {
|
if (options.needBody) {
|
||||||
return {
|
return {
|
||||||
|
|||||||
Reference in New Issue
Block a user