diff --git a/packages/next-plugin-storybook/preset.js b/packages/next-plugin-storybook/preset.js index 57f3605ea321b..12ccb983e6063 100644 --- a/packages/next-plugin-storybook/preset.js +++ b/packages/next-plugin-storybook/preset.js @@ -28,7 +28,7 @@ async function webpackFinal(config) { config.module.rules = [ ...config.module.rules.filter((rule) => { // the rules we're filtering use RegExp for the test - if (!rule.test instanceof RegExp) return true + if (!(rule.test instanceof RegExp)) return true // use Next.js' built-in CSS if (rule.test.test('hello.css')) { return false