From: Thibaut Girka Date: Mon, 1 Apr 2019 19:28:31 +0000 (+0200) Subject: Merge branch 'master' into glitch-soc/merge-upstream X-Git-Url: https://git.xn--scling-oua.cat.family/?a=commitdiff_plain;h=12dae9d58316bec32adaac016998ab1cf69d2b45;p=mastodon.git Merge branch 'master' into glitch-soc/merge-upstream Conflicts: - app/models/form/admin_settings.rb - config/locales/ja.yml --- 12dae9d58316bec32adaac016998ab1cf69d2b45 diff --cc app/models/form/admin_settings.rb index 0fcbd0605,d3af8c30f..5b71dfad5 --- a/app/models/form/admin_settings.rb +++ b/app/models/form/admin_settings.rb @@@ -26,8 -25,9 +26,11 @@@ class Form::AdminSetting preview_sensitive_media custom_css profile_directory + hide_followers_count + flavour_and_skin + thumbnail + hero + mascot ).freeze BOOLEAN_KEYS = %i( @@@ -70,10 -65,9 +73,10 @@@ return false unless valid? KEYS.each do |key| + next if PSEUDO_KEYS.include?(key) value = instance_variable_get("@#{key}") - if UPLOAD_KEYS.include?(key) + if UPLOAD_KEYS.include?(key) && !value.nil? upload = SiteUpload.where(var: key).first_or_initialize(var: key) upload.update(file: value) else diff --cc config/locales/en.yml index 682f85406,705024ff5..a8a19f85d --- a/config/locales/en.yml +++ b/config/locales/en.yml @@@ -636,8 -633,8 +636,9 @@@ en all: All changes_saved_msg: Changes successfully saved! copy: Copy + order_by: Order by save_changes: Save changes + use_this: Use this validation_errors: one: Something isn't quite right yet! Please review the error below other: Something isn't quite right yet! Please review %{count} errors below diff --cc config/locales/ja.yml index 054d90833,09214a937..85a310953 --- a/config/locales/ja.yml +++ b/config/locales/ja.yml @@@ -629,8 -633,8 +633,9 @@@ ja all: すべて changes_saved_msg: 正常に変更されました! copy: コピー + order_by: 並び順 save_changes: 変更を保存 + use_this: これを使う validation_errors: one: エラーが発生しました! 以下のエラーを確認してください other: エラーが発生しました! 以下の%{count}個のエラーを確認してください @@@ -823,7 -861,7 +862,8 @@@ edit_profile: プロフィールを編集 export: データのエクスポート featured_tags: 注目のハッシュタグ + flavours: フレーバー + identity_proofs: Identity proofs import: データのインポート migrate: アカウントの引っ越し notifications: 通知