diff options
Diffstat (limited to 'app/lib')
-rw-r--r-- | app/lib/user_settings_decorator.rb | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/app/lib/user_settings_decorator.rb b/app/lib/user_settings_decorator.rb index a851ff217..182fb640b 100644 --- a/app/lib/user_settings_decorator.rb +++ b/app/lib/user_settings_decorator.rb @@ -15,13 +15,14 @@ class UserSettingsDecorator private def process_update - user.settings['notification_emails'] = merged_notification_emails if change?('notification_emails') - user.settings['interactions'] = merged_interactions if change?('interactions') - user.settings['default_privacy'] = default_privacy_preference if change?('setting_default_privacy') user.settings['default_local'] = default_local_preference if change?('setting_default_local') user.settings['always_local'] = always_local_preference if change?('setting_always_local') user.settings['rawr_federated'] = rawr_federated_preference if change?('setting_rawr_federated') user.settings['hide_stats'] = hide_stats_preference if change?('setting_hide_stats') + user.settings['hide_captions'] = hide_captions_preference if change?('setting_hide_captions') + user.settings['notification_emails'] = merged_notification_emails if change?('notification_emails') + user.settings['interactions'] = merged_interactions if change?('interactions') + user.settings['default_privacy'] = default_privacy_preference if change?('setting_default_privacy') user.settings['default_sensitive'] = default_sensitive_preference if change?('setting_default_sensitive') user.settings['default_language'] = default_language_preference if change?('setting_default_language') user.settings['unfollow_modal'] = unfollow_modal_preference if change?('setting_unfollow_modal') @@ -71,6 +72,10 @@ class UserSettingsDecorator boolean_cast_setting 'setting_hide_stats' end + def hide_captions_preference + boolean_cast_setting 'setting_hide_captions' + end + def default_sensitive_preference boolean_cast_setting 'setting_default_sensitive' end |