Skip to content

Commit 011ed56

Browse files
author
evilebottnawi
committed
Refactor: simplify code.
1 parent 628bd4b commit 011ed56

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

src/NunjucksWebpackPlugin.js

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -60,13 +60,10 @@ class NunjucksWebpackPlugin {
6060
fileDependencies.push(template.from);
6161
}
6262

63-
const localContext = template.context ? template.context : null;
64-
const localCallback = template.callback ? template.callback : null;
65-
6663
const res = nunjucks.render(
6764
template.from,
68-
Object.assign({}, localContext),
69-
localCallback
65+
template.context ? template.context : null,
66+
template.callback ? template.callback : null
7067
);
7168

7269
let webpackTo = template.to;

0 commit comments

Comments
 (0)