Commit 9c3346f5 by Kyle MacFarlane Committed by Timothée Peignier

fix context bug again, this time for javascript

Signed-off-by: Timothée Peignier <timothee.peignier@tryphon.org>
parent 7b23de2f
...@@ -69,7 +69,7 @@ class CompressedJSNode(template.Node): ...@@ -69,7 +69,7 @@ class CompressedJSNode(template.Node):
context = {} context = {}
if not 'template' in package: if not 'template' in package:
package['template'] = "pipeline/js.html" package['template'] = "pipeline/js.html"
if not 'context' in package: if 'context' in package:
context = package['context'] context = package['context']
context.update({ context.update({
'url': self.packager.individual_url(path) 'url': self.packager.individual_url(path)
...@@ -85,7 +85,7 @@ class CompressedJSNode(template.Node): ...@@ -85,7 +85,7 @@ class CompressedJSNode(template.Node):
def render_inline(self, package, js): def render_inline(self, package, js):
context = {} context = {}
if not 'context' in package: if 'context' in package:
context = package['context'] context = package['context']
context.update({ context.update({
'source': js 'source': js
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment