lib/i18n/tasks/configuration.rb in i18n-tasks-0.9.21 vs lib/i18n/tasks/configuration.rb in i18n-tasks-0.9.22
- old
+ new
@@ -55,10 +55,11 @@
# translation config
# @return [Hash{String => String,Hash,Array}]
def translation_config
@config_sections[:translation] ||= begin
conf = (config[:translation] || {}).with_indifferent_access
- conf[:api_key] ||= ENV['GOOGLE_TRANSLATE_API_KEY'] if ENV.key?('GOOGLE_TRANSLATE_API_KEY')
+ conf[:google_translate_api_key] = ENV['GOOGLE_TRANSLATE_API_KEY'] if ENV.key?('GOOGLE_TRANSLATE_API_KEY')
+ conf[:deepl_api_key] = ENV['DEEPL_AUTH_KEY'] if ENV.key?('DEEPL_AUTH_KEY')
conf
end
end
# @return [Array<String>] all available locales, base_locale is always first