Skip to content

Commit

Permalink
fix(projects): fix axios createRequest: add default state
Browse files Browse the repository at this point in the history
  • Loading branch information
honghuangdc committed Apr 9, 2024
1 parent f4a9cf8 commit d6eda8f
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions packages/axios/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,7 @@ export function createRequest<ResponseData = any, State = Record<string, unknown

request.cancelRequest = cancelRequest;
request.cancelAllRequest = cancelAllRequest;
request.state = {} as State;

return request;
}
Expand Down

0 comments on commit d6eda8f

Please sign in to comment.