Skip to content

Commit

Permalink
refactor(botonic-cli): add type any to error
Browse files Browse the repository at this point in the history
  • Loading branch information
Iru89 committed Aug 22, 2024
1 parent 69019a6 commit cba6d26
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/botonic-cli/src/botonic-api-service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -171,8 +171,8 @@ export class BotonicAPIService {
): Promise<any> {
try {
return await requestFn()

Check warning on line 173 in packages/botonic-cli/src/botonic-api-service.ts

View check run for this annotation

Codecov / codecov/patch

packages/botonic-cli/src/botonic-api-service.ts#L172-L173

Added lines #L172 - L173 were not covered by tests
} catch (error) {
if (error.response && error.response.status === 401) {
} catch (error: any) {
if (error.response?.status === 401) {
await this.refreshToken()
return await requestFn()

Check warning on line 177 in packages/botonic-cli/src/botonic-api-service.ts

View check run for this annotation

Codecov / codecov/patch

packages/botonic-cli/src/botonic-api-service.ts#L176-L177

Added lines #L176 - L177 were not covered by tests
} else {
Expand Down

0 comments on commit cba6d26

Please sign in to comment.