Skip to content

Commit

Permalink
StringBuffer: Only check literals when :check_literal => true
Browse files Browse the repository at this point in the history
  • Loading branch information
judofyr committed Feb 20, 2010
1 parent ab6e3ef commit 9db9f43
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/temple/core.rb
Expand Up @@ -64,7 +64,7 @@ def preamble; buffer " = ''" end
def postamble; buffer end

def on_dynamic(code)
if Utils.literal_string?(code)
if @options[:check_literal] && Utils.literal_string?(code)
buffer " << (#{code})"
else
buffer " << (#{code}).to_s"
Expand Down

0 comments on commit 9db9f43

Please sign in to comment.