lib/nanoc/helpers/capturing.rb in nanoc-4.12.18 vs lib/nanoc/helpers/capturing.rb in nanoc-4.12.19
- old
+ new
@@ -20,11 +20,11 @@
content_string = capture(&block)
# Get existing contents and prep for store
compiled_content_store = @item._context.compiled_content_store
rep = @item.reps[:default]._unwrap
- capture_name = "__capture_#{@name}".to_sym
+ capture_name = :"__capture_#{@name}"
old_content_string =
case existing_behavior
when :overwrite
''
when :append
@@ -72,10 +72,10 @@
return run
end
end
compiled_content_store = @config._context.compiled_content_store
- content = compiled_content_store.get(rep, "__capture_#{@name}".to_sym)
+ content = compiled_content_store.get(rep, :"__capture_#{@name}")
content&.string
end
end
# @overload content_for(name, &block)