Skip to content

Commit

Permalink
fix: typing boolean return value
Browse files Browse the repository at this point in the history
  • Loading branch information
Tofandel committed Mar 8, 2022
1 parent ca503a5 commit 595679f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/inertia/src/router.ts
Original file line number Diff line number Diff line change
Expand Up @@ -152,11 +152,11 @@ export class Router {
}

protected isLocationVisitResponse(response: AxiosResponse): boolean {
return response && response.status === 409 && response.headers['x-inertia-location']
return !!response && response.status === 409 && !!response.headers['x-inertia-location']
}

protected isInertiaResponse(response: AxiosResponse): boolean {
return response?.headers['x-inertia']
return !!response?.headers['x-inertia']
}

protected createVisitId(): VisitId {
Expand Down

0 comments on commit 595679f

Please sign in to comment.