Skip to content

Commit

Permalink
+"\n" doesn't work (?), use "\n".dup
Browse files Browse the repository at this point in the history
  • Loading branch information
MSP-Greg committed Jun 22, 2024
1 parent dcd8b98 commit 5d92adc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ruby_info.rb
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ def run
# log constants
cnsts = Object.constants.grep(/\ARUBY_/).sort
cnsts.reject! { |c| c == :RUBY_DESCRIPTION }
str = +"\n"
str = "\n".dup
cnsts.each { |c| str << "#{c.to_s.ljust 20} #{Object.const_get c}\n" }
puts str, ''

Expand Down

0 comments on commit 5d92adc

Please sign in to comment.