Skip to content

Commit

Permalink
Fix deprecated way of calling ERB.new in Ruby 3.1
Browse files Browse the repository at this point in the history
See https://bugs.ruby-lang.org/issues/14256 - `eoutvar` is supposed to
be passed as a keyword argument now.

In Ruby 3.1 (but probably since some earlier version than that), the old
way was triggering a deprecation warning.
  • Loading branch information
generalmimon committed May 30, 2023
1 parent 57e387c commit 8bba62c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion _build/build-html
Original file line number Diff line number Diff line change
Expand Up @@ -457,7 +457,7 @@ class FormatPagesGenerator

def erb(name)
bin_dir = File.expand_path(File.dirname(__FILE__))
ERB.new(File.read("#{bin_dir}/#{name}.html.erb"), nil, nil, "_erbout_#{name}")
ERB.new(File.read("#{bin_dir}/#{name}.html.erb"), eoutvar: "_erbout_#{name}")
end
end

Expand Down

0 comments on commit 8bba62c

Please sign in to comment.