Skip to content

Commit bb8b62d

Browse files
authored
Fix usage of rollupOptions.onWarn (#53)
1 parent eb34ee0 commit bb8b62d

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

src/index.ts

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -199,10 +199,7 @@ export const nodePolyfills = (options: PolyfillOptions = {}): Plugin => {
199199
build: {
200200
rollupOptions: {
201201
onwarn: (warning, rollupWarn) => {
202-
handleCircularDependancyWarning(warning, rollupWarn)
203-
204-
// Make sure the predefined `onwarn` handler is called too.
205-
config.build?.rollupOptions?.onwarn?.(warning, rollupWarn)
202+
handleCircularDependancyWarning(warning, config.build?.rollupOptions?.onwarn ?? rollupWarn)
206203
},
207204
plugins: [
208205
{

0 commit comments

Comments
 (0)