Skip to content

Commit

Permalink
set user locale when exporting
Browse files Browse the repository at this point in the history
  • Loading branch information
bmesuere committed Oct 21, 2023
1 parent 95a41ee commit f045690
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions app/helpers/export_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ def initialize(**kwargs)
@list = kwargs[:list]
@users = kwargs[:users]
@for_user = kwargs[:for_user]
I18n.locale = @for_user&.lang # set locale to use correct exercise names

Check warning on line 25 in app/helpers/export_helper.rb

View check run for this annotation

Codecov / codecov/patch

app/helpers/export_helper.rb#L25

Added line #L25 was not covered by tests
case @item
when Series
@list = @item.exercises if all?
Expand Down

0 comments on commit f045690

Please sign in to comment.