From 148c4da23d06ed079bb73f38eeb3ce6aa1519c6f Mon Sep 17 00:00:00 2001 From: Robin Ward Date: Wed, 4 May 2016 17:00:58 -0400 Subject: [PATCH] FIX: Server side missing jQuery --- .../discourse/lib/ember_compat_handlebars.js | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/app/assets/javascripts/discourse/lib/ember_compat_handlebars.js b/app/assets/javascripts/discourse/lib/ember_compat_handlebars.js index 01aee3fc046..46e31407893 100644 --- a/app/assets/javascripts/discourse/lib/ember_compat_handlebars.js +++ b/app/assets/javascripts/discourse/lib/ember_compat_handlebars.js @@ -69,10 +69,18 @@ RawHandlebars.JavaScriptCompiler.prototype.namespace = "Discourse.EmberCompatHandlebars"; function buildPath(blk, args) { - return $.extend({ type: "PathExpression", - data: false, - depth: blk.path.depth, - loc: blk.path.loc }, args); + + const result = { type: "PathExpression", + data: false, + depth: blk.path.depth, + loc: blk.path.loc }; + + // Server side precompile doesn't have jquery.extend + Object.keys(args).forEach(function (a) { + result[a] = args[a]} + ); + + return result; } function replaceGet(ast) {