Skip to content

Commit

Permalink
Merge pull request #691 from tom-lord/interpolate_documentation_synta…
Browse files Browse the repository at this point in the history
…x_fix

Fix syntax in documentation for I18n::Backend::Base.interpolate
  • Loading branch information
radar authored May 6, 2024
2 parents 73fd07e + 305edf4 commit 5bec0bc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/i18n/backend/base.rb
Original file line number Diff line number Diff line change
Expand Up @@ -188,8 +188,8 @@ def pluralize(locale, entry, count)
#
# if the given subject is an array then:
# each element of the array is recursively interpolated (until it finds a string)
# method interpolates ["yes, %{user}", ["maybe no, %{user}, "no, %{user}"]], :user => "bartuz"
# # => "["yes, bartuz",["maybe no, bartuz", "no, bartuz"]]"
# method interpolates ["yes, %{user}", ["maybe no, %{user}", "no, %{user}"]], :user => "bartuz"
# # => ["yes, bartuz", ["maybe no, bartuz", "no, bartuz"]]
def interpolate(locale, subject, values = EMPTY_HASH)
return subject if values.empty?

Expand Down

0 comments on commit 5bec0bc

Please sign in to comment.