Use remote translations objects instead of hashes
This way we can simplify the code dealing with the translatable association.
This commit is contained in:
@@ -13,8 +13,6 @@ class Layout::RemoteTranslationsButtonComponent < ApplicationComponent
|
||||
private
|
||||
|
||||
def display_remote_translation_button?
|
||||
remote_translations.none? do |remote_translation|
|
||||
RemoteTranslation.remote_translation_enqueued?(remote_translation)
|
||||
end
|
||||
remote_translations.none?(&:enqueued?)
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user