Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitb140983

Browse files
authored
refactor: clean up api/error.ts (#4542)
This removes an eslint-disable lint and updates the `err` type to`unknown` instead of `any` which is more correct.
1 parent94db085 commitb140983

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

‎site/src/api/errors.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,7 @@ export type ApiError = AxiosError<ApiErrorResponse> & {
2323
response:AxiosResponse<ApiErrorResponse>
2424
}
2525

26-
// eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types, @typescript-eslint/no-explicit-any
27-
exportconstisApiError=(err:any):err isApiError=>{
26+
exportconstisApiError=(err:unknown):err isApiError=>{
2827
if(axios.isAxiosError(err)){
2928
constresponse=err.response?.data
3029
if(!response){

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp