Skip to content

Commit

Permalink
refactor: removed return await
Browse files Browse the repository at this point in the history
  • Loading branch information
arthurfiorette committed Jan 10, 2022
1 parent 88d45cc commit c3661a6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/util/cache-predicate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ import type { CachePredicate } from './types';
export async function testCachePredicate<R = unknown, D = unknown>(
response: CacheAxiosResponse<R, D>,
predicate: CachePredicate<R, D>
) {
): Promise<boolean> {
if (typeof predicate === 'function') {
return await predicate(response);
return predicate(response);
}

const { statusCheck, responseMatch, containsHeaders } = predicate;
Expand Down

0 comments on commit c3661a6

Please sign in to comment.