Prefer delegated nil-wrapping methods to safe navigation (#35541)
This commit is contained in:
@@ -30,9 +30,9 @@
|
||||
= t('admin.accounts.suspended')
|
||||
- elsif account.silenced?
|
||||
= t('admin.accounts.silenced')
|
||||
- elsif account.local? && account.user&.disabled?
|
||||
- elsif account.local? && account.user_disabled?
|
||||
= t('admin.accounts.disabled')
|
||||
- elsif account.local? && !account.user&.confirmed?
|
||||
- elsif account.local? && !account.user_confirmed?
|
||||
= t('admin.accounts.confirming')
|
||||
- elsif account.local? && !account.user_approved?
|
||||
= t('admin.accounts.pending')
|
||||
|
||||
@@ -34,7 +34,7 @@
|
||||
%tr
|
||||
%th= t('admin.accounts.email_status')
|
||||
%td
|
||||
- if account.user&.confirmed?
|
||||
- if account.user_confirmed?
|
||||
= t('admin.accounts.confirmed')
|
||||
- else
|
||||
= t('admin.accounts.confirming')
|
||||
|
||||
@@ -42,7 +42,7 @@
|
||||
%span.red= t('admin.accounts.suspended')
|
||||
- elsif target_account.silenced?
|
||||
%span.red= t('admin.accounts.silenced')
|
||||
- elsif target_account.user&.disabled?
|
||||
- elsif target_account.user_disabled?
|
||||
%span.red= t('admin.accounts.disabled')
|
||||
- else
|
||||
%span.neutral= t('admin.accounts.no_limits_imposed')
|
||||
|
||||
Reference in New Issue
Block a user