Skip to content
This repository was archived by the owner on Nov 30, 2018. It is now read-only.

Commit 630811c

Browse files
committed
Avoid n+1 query issue when eager_loading is used
1 parent 894c778 commit 630811c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/active_admin/globalize/index_table_for_extension.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ def translation_status
1212
end
1313
def translation_status_flags
1414
column I18n.t("active_admin.globalize.translations") do |obj|
15-
obj.translated_locales.map { |l| flag_icon(l) }.join(' ').html_safe
15+
obj.translations.map(&:locale).sort.map { |l| flag_icon(l) }.join(' ').html_safe
1616
end
1717
end
1818
end

0 commit comments

Comments
 (0)