diff --git a/app/models/admin_dashboard_data.rb b/app/models/admin_dashboard_data.rb index a4caf42bc..b644bcd9f 100644 --- a/app/models/admin_dashboard_data.rb +++ b/app/models/admin_dashboard_data.rb @@ -20,6 +20,21 @@ class AdminDashboardData 'notify_user_private_messages' ] + def problems + [ rails_env_check, + host_names_check, + gc_checks, + sidekiq_check || queue_size_check || clockwork_check, + ram_check, + facebook_config_check, + twitter_config_check, + github_config_check, + failing_emails_check, + default_logo_check, + contact_email_check, + title_check ].compact + end + def self.fetch_all AdminDashboardData.new end @@ -39,20 +54,6 @@ class AdminDashboardData ) end - def problems - [ rails_env_check, - host_names_check, - gc_checks, - sidekiq_check || queue_size_check || clockwork_check, - ram_check, - facebook_config_check, - twitter_config_check, - github_config_check, - failing_emails_check, - default_logo_check, - contact_email_check ].compact - end - def rails_env_check I18n.t("dashboard.rails_env_warning", env: Rails.env) unless Rails.env == 'production' end @@ -112,4 +113,8 @@ class AdminDashboardData return I18n.t('dashboard.contact_email_missing') if !SiteSetting.contact_email.present? return I18n.t('dashboard.contact_email_invalid') if !(SiteSetting.contact_email =~ User::EMAIL) end + + def title_check + I18n.t('dashboard.title_nag') if SiteSetting.title == SiteSetting.defaults[:title] + end end \ No newline at end of file diff --git a/config/locales/server.en.yml b/config/locales/server.en.yml index cf04b78f3..c4a1bc877 100644 --- a/config/locales/server.en.yml +++ b/config/locales/server.en.yml @@ -350,6 +350,7 @@ en: default_logo_warning: "You haven't customized the logo images for your site. Update logo_url, logo_small_url, and favicon_url in the Site Settings." contact_email_missing: "You haven't provided a contact email for your site. Please update contact_email in the Site Settings." contact_email_invalid: "The site contact email is invalid. Please update contact_email in the Site Settings." + title_nag: "The title Site Setting is still set to the default value. Please update it with your site's title in the Site Settings." content_types: education_new_reply: