Skip to content

Commit

Permalink
Unescape parens expression in buildTmplFn: Fix for https://github.com…
Browse files Browse the repository at this point in the history
  • Loading branch information
BorisMoore committed Nov 23, 2010
1 parent 180211f commit 3fd23ad
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion jquery.tmpl.js
Original file line number Diff line number Diff line change
Expand Up @@ -341,7 +341,7 @@
args = args ? ("," + unescape( args ) + ")") : (parens ? ")" : "");
// Support for target being things like a.toLowerCase();
// In that case don't call with template item as 'this' pointer. Just evaluate...
expr = parens ? (target.indexOf(".") > -1 ? target + parens : ("(" + target + ").call($item" + args)) : target;
expr = parens ? (target.indexOf(".") > -1 ? target + unescape( parens ) : ("(" + target + ").call($item" + args)) : target;
exprAutoFnDetect = parens ? expr : "(typeof(" + target + ")==='function'?(" + target + ").call($item):(" + target + "))";
} else {
exprAutoFnDetect = expr = def.$1 || "null";
Expand Down
1 change: 1 addition & 0 deletions jquery.tmplPlus.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
/*!
* preBeta1.0.1
* Additional templating features or support for more advanced/less common scenarios.
* Requires jquery.tmpl.js
* http://github.com/jquery/jquery-tmpl
Expand Down

0 comments on commit 3fd23ad

Please sign in to comment.