Skip to content

Commit

Permalink
fixed build issues
Browse files Browse the repository at this point in the history
  • Loading branch information
51ngul4r1ty committed Feb 2, 2024
1 parent 76d3377 commit c10e22a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions packages/rest-fetch/src/restApiFetch.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ export class RestApiFetch<ST = any, FT = string> {
this.format = options?.format ?? REST_API_FETCH_OPTIONS_DEFAULT.format;
this.defaultHeaders = {};
}
public onAuthFailure: AsyncAuthFailureHandler;
public onAuthFailure: AsyncAuthFailureHandler | undefined = undefined;
private async handleAuthFailure(): Promise<boolean> {
if (this.onAuthFailure) {
return await this.onAuthFailure();
Expand Down Expand Up @@ -118,7 +118,7 @@ export class RestApiFetch<ST = any, FT = string> {
}
return null;
}
private mapStringToError(error: string): RestApiFetchError {
private mapStringToError(error: string | null): RestApiFetchError {
return {
message: error,
status: StatusCodes.INTERNAL_SERVER_ERROR,
Expand Down
2 changes: 1 addition & 1 deletion packages/rest-fetch/src/restApiFetchTypes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import {
} from "./restApiFetchEnums";

export type RestApiFetchError<T = any> = {
message: string;
message: string | null;
status: number;
errorType: RestApiFetchErrorType;
errorSubType: RestApiFetchErrorSubType;
Expand Down

0 comments on commit c10e22a

Please sign in to comment.