Permalink
Browse files

no sense in yielding twice in liquid template

  • Loading branch information...
1 parent b7a24b7 commit 3f69cb4f933804308ed7498b5d3a60277f3d312a @rtomayko committed Feb 22, 2010
Showing with 1 addition and 2 deletions.
  1. +1 −2 lib/tilt.rb
View
@@ -412,9 +412,8 @@ def evaluate(scope, locals, &block)
scope = scope.to_h.inject({}){ |h,(k,v)| h[k.to_s] = v ; h }
locals = scope.merge(locals)
end
- # TODO: Is it possible to lazy yield ?
locals['yield'] = block.nil? ? '' : yield
- locals['content'] = block.nil? ? '' : yield
+ locals['content'] = locals['yield']
@engine.render(locals)
end
end

0 comments on commit 3f69cb4

Please sign in to comment.