forked from mzgoddard/hard-source-webpack-plugin
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit 33b306b
fix: memory leak in TransformNormalModuleFactoryPlugin (mzgoddard#414)
Problem: plugin wraps createLoaderContext without checking if it was
already done before. As a result, in a watch mode more and more wrappers
get added on top of the function and eat more and more memory. Fixed by
saving original function on module instance itself and wrapping saved
function instead.1 parent e370f1f commit 33b306b
1 file changed
+4
-3
lines changedLines changed: 4 additions & 3 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
38 | 38 |
| |
39 | 39 |
| |
40 | 40 |
| |
41 | - | ||
41 | + | ||
42 | + | ||
43 | + | ||
42 | 44 |
| |
43 | 45 |
| |
44 | - | ||
45 | - | ||
46 | + | ||
46 | 47 |
| |
47 | 48 |
| |
48 | 49 |
| |
|
0 commit comments