Skip to content

Commit fbe832a

Browse files
hsbtclaude
andauthored
Fix wrong receiver in eoutvar example for #src (#123)
The example was updated to assign the ERB instance to `erb` instead of `template`, but the following line still called `template.src`. Since `template` is a String there, the example raises NoMethodError. Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
1 parent ba3086d commit fbe832a

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

lib/erb.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -889,7 +889,7 @@ def make_compiler(trim_mode)
889889
#
890890
# ```
891891
# erb = ERB.new(template, eoutvar: '_foo')
892-
# puts template.src.split('; ')
892+
# puts erb.src.split('; ')
893893
# #coding:UTF-8
894894
# _foo = +''
895895
# _foo.<< "The time is ".freeze

0 commit comments

Comments
 (0)