Fix admin dashboard missing latest features (#11505)
Fix redis-namespace deprecation warning about administrative commands
This commit is contained in:
		
							parent
							
								
									9072fe5ab6
								
							
						
					
					
						commit
						dd38c280a5
					
				
					 3 changed files with 19 additions and 1 deletions
				
			
		| 
						 | 
				
			
			@ -28,9 +28,12 @@ module Admin
 | 
			
		|||
      @pam_enabled           = ENV['PAM_ENABLED'] == 'true'
 | 
			
		||||
      @hidden_service        = ENV['ALLOW_ACCESS_TO_HIDDEN_SERVICE'] == 'true'
 | 
			
		||||
      @trending_hashtags     = TrendingTags.get(10, filtered: false)
 | 
			
		||||
      @authorized_fetch      = authorized_fetch_mode?
 | 
			
		||||
      @whitelist_enabled     = whitelist_mode?
 | 
			
		||||
      @profile_directory     = Setting.profile_directory
 | 
			
		||||
      @timeline_preview      = Setting.timeline_preview
 | 
			
		||||
      @spam_check_enabled    = Setting.spam_check_enabled
 | 
			
		||||
      @trends_enabled        = Setting.trends
 | 
			
		||||
    end
 | 
			
		||||
 | 
			
		||||
    private
 | 
			
		||||
| 
						 | 
				
			
			@ -40,7 +43,13 @@ module Admin
 | 
			
		|||
    end
 | 
			
		||||
 | 
			
		||||
    def redis_info
 | 
			
		||||
      @redis_info ||= Redis.current.info
 | 
			
		||||
      @redis_info ||= begin
 | 
			
		||||
        if Redis.current.is_a?(Redis::Namespace)
 | 
			
		||||
          Redis.current.redis.info
 | 
			
		||||
        else
 | 
			
		||||
          Redis.current.info
 | 
			
		||||
        end
 | 
			
		||||
      end
 | 
			
		||||
    end
 | 
			
		||||
  end
 | 
			
		||||
end
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -49,6 +49,8 @@
 | 
			
		|||
          = feature_hint(link_to(t('admin.dashboard.feature_profile_directory'), edit_admin_settings_path), @profile_directory)
 | 
			
		||||
        %li
 | 
			
		||||
          = feature_hint(link_to(t('admin.dashboard.feature_timeline_preview'), edit_admin_settings_path), @timeline_preview)
 | 
			
		||||
        %li
 | 
			
		||||
          = feature_hint(link_to(t('admin.dashboard.trends'), edit_admin_settings_path), @trends_enabled)
 | 
			
		||||
        %li
 | 
			
		||||
          = feature_hint(link_to(t('admin.dashboard.feature_relay'), admin_relays_path), @relay_enabled)
 | 
			
		||||
        %li
 | 
			
		||||
| 
						 | 
				
			
			@ -90,6 +92,10 @@
 | 
			
		|||
          = feature_hint(t('admin.dashboard.search'), @search_enabled)
 | 
			
		||||
        %li
 | 
			
		||||
          = feature_hint(t('admin.dashboard.single_user_mode'), @single_user_mode)
 | 
			
		||||
        %li
 | 
			
		||||
          = feature_hint(t('admin.dashboard.authorized_fetch_mode'), @authorized_fetch)
 | 
			
		||||
        %li
 | 
			
		||||
          = feature_hint(t('admin.dashboard.whitelist_mode'), @whitelist_mode)
 | 
			
		||||
        %li
 | 
			
		||||
          = feature_hint('LDAP', @ldap_enabled)
 | 
			
		||||
        %li
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -247,6 +247,7 @@ en:
 | 
			
		|||
      updated_msg: Emoji successfully updated!
 | 
			
		||||
      upload: Upload
 | 
			
		||||
    dashboard:
 | 
			
		||||
      authorized_fetch_mode: Authorized fetch mode
 | 
			
		||||
      backlog: backlogged jobs
 | 
			
		||||
      config: Configuration
 | 
			
		||||
      feature_deletions: Account deletions
 | 
			
		||||
| 
						 | 
				
			
			@ -270,6 +271,7 @@ en:
 | 
			
		|||
      week_interactions: interactions this week
 | 
			
		||||
      week_users_active: active this week
 | 
			
		||||
      week_users_new: users this week
 | 
			
		||||
      whitelist_mode: Whitelist mode
 | 
			
		||||
    domain_allows:
 | 
			
		||||
      add_new: Whitelist domain
 | 
			
		||||
      created_msg: Domain has been successfully whitelisted
 | 
			
		||||
| 
						 | 
				
			
			@ -565,6 +567,7 @@ en:
 | 
			
		|||
    status:
 | 
			
		||||
      account_status: Account status
 | 
			
		||||
      confirming: Waiting for e-mail confirmation to be completed.
 | 
			
		||||
      functional: Your account is fully operational.
 | 
			
		||||
      pending: Your application is pending review by our staff. This may take some time. You will receive an e-mail if your application is approved.
 | 
			
		||||
    trouble_logging_in: Trouble logging in?
 | 
			
		||||
  authorize_follow:
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		
		Reference in a new issue