Skip to content

Commit

Permalink
Simpler country names
Browse files Browse the repository at this point in the history
  • Loading branch information
Calyhre committed May 18, 2017
1 parent a5de970 commit a8e2b0a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/controllers/application_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ def best_deals
lowest = games.flat_map(&:prices).min_by { |price| price.value.exchange_to('USD') }
next if !lowest.present?
rates = currencies.map { |c| lowest.value.exchange_to(c) }
rows << [game.title, lowest.country].concat(rates)
rows << [game.title, ISO3166::Country[lowest.country].translation('en')].concat(rates)
end
end

Expand Down Expand Up @@ -72,7 +72,7 @@ def glossary

countries.each do |code|
country = ISO3166::Country[code]
rows << [code, country.name, country.currency.iso_code, country.currency.name]
rows << [code, country.translation('en'), country.currency.iso_code, country.currency.name]
end

rows << []
Expand Down

0 comments on commit a8e2b0a

Please sign in to comment.