Skip to content

Commit

Permalink
Simplify {@select}
Browse files Browse the repository at this point in the history
  • Loading branch information
Seth Kinast committed Apr 18, 2015
1 parent def2b56 commit 43dcf6e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/dust-helpers.js
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ var helpers = {
* {@math}
* @param key first value
* @param method {String} operation to perform
* @param operand second value (not required for operations like `abs` or ``)
* @param operand second value (not required for operations like `abs`)
* @param round if truthy, round() the result
*/
"math": function (chunk, context, bodies, params) {
Expand Down Expand Up @@ -297,7 +297,7 @@ var helpers = {
key;

if (params.hasOwnProperty("key")) {
key = dust.helpers.tap(params.key, chunk, context);
key = context.resolve(params.key);
if (body) {
context = addSelectState(context, key);
chunk = chunk.render(body, context);
Expand All @@ -314,7 +314,7 @@ var helpers = {
/**
* Truth test helpers
* @param key a value or reference to use as the left-hand side of comparisons
* @param value a value or reference to use as the left-hand side of comparisons
* @param value a value or reference to use as the right-hand side of comparisons
* @param type if specified, `key` and `value` will be forcibly cast to this type
*/
"eq": truthTest('eq', function(left, right) {
Expand Down

0 comments on commit 43dcf6e

Please sign in to comment.