Skip to content

Commit cb3345d

Browse files
Fix crash while watching file paths
1 parent 6d04888 commit cb3345d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

plugin.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ class SwiftWebpackPlugin {
5151
log("Watching " + this.packageDirectory)
5252
this.wp.watch([], [this.packageDirectory], Date.now() - 10000);
5353
this.wp.on('change', (filePath, mtime, explanation) => {
54-
if (!filePath) return;
54+
if (!filePath || typeof filePath != 'string') return;
5555
if (this.ignoring.some(i => filePath.includes(i)))
5656
return;
5757
this._compile()

0 commit comments

Comments
 (0)