From e8b245b1d662e8883834ea62432f2fc1d507a116 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Hannes=20Born=C3=B6?= Date: Fri, 17 Feb 2023 17:09:58 +0100 Subject: [PATCH] Fix next/font error parsing on windows --- .../plugins/wellknown-errors-plugin/parseNextFontError.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/next/src/build/webpack/plugins/wellknown-errors-plugin/parseNextFontError.ts b/packages/next/src/build/webpack/plugins/wellknown-errors-plugin/parseNextFontError.ts index e86ce98bba1ff..217cbe9c0faa0 100644 --- a/packages/next/src/build/webpack/plugins/wellknown-errors-plugin/parseNextFontError.ts +++ b/packages/next/src/build/webpack/plugins/wellknown-errors-plugin/parseNextFontError.ts @@ -8,7 +8,7 @@ export function getNextFontError( const resourceResolveData = module.resourceResolveData if ( !module.loaders.find((loader: any) => - loader.loader.includes('next-font-loader/index.js') + /next-font-loader[/\\]index.js/.test(loader.loader) ) ) { return false