Skip to content

Commit

Permalink
Fix linting
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolo-ribaudo committed Jan 8, 2024
1 parent a71f8f8 commit f05faa9
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions packages/babel-helper-import-to-platform-api/src/index.ts
Expand Up @@ -170,7 +170,7 @@ export function importToPlatformApi(
throw new Error("Internal Babel error: unreachable code.");
}

buildFetchAsync ??= buildFetchSync!;
buildFetchAsync ??= buildFetchSync;
const buildFetchAsyncWrapped: typeof buildFetchAsync = (expression, path) => {
if (t.isStringLiteral(expression)) {
return template.expression.ast`
Expand All @@ -187,9 +187,9 @@ export function importToPlatformApi(
};

return {
buildFetch: buildFetchSync! || buildFetchAsync,
buildFetch: buildFetchSync || buildFetchAsync,
buildFetchAsync: buildFetchAsyncWrapped,
needsAwait: !buildFetchSync!,
needsAwait: !buildFetchSync,
};
}

Expand Down

0 comments on commit f05faa9

Please sign in to comment.