Skip to content

Commit

Permalink
fixed global config file import issue on windows
Browse files Browse the repository at this point in the history
  • Loading branch information
RafidMuhymin committed Nov 20, 2022
1 parent 02dcfac commit 0d8ce1b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/astro-imagetools/utils/runtimeChecks.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,9 @@ const configFile = await findUp([
"astro-imagetools.config.mjs",
]);

const configFunction = configFile ? await import(configFile) : null;
const configFunction = configFile
? await import(configFile).catch(async () => await import("/" + configFile))
: null;

const rawGlobalConfigOptions = configFunction?.default ?? {};

Expand Down

0 comments on commit 0d8ce1b

Please sign in to comment.