diff options
| author | wn_ <invalid@email.com> | 2024-08-04 15:42:11 +0000 |
|---|---|---|
| committer | wn_ <invalid@email.com> | 2024-08-04 15:42:11 +0000 |
| commit | 9dd4102c7fe2ddfc67f91ad9034d734a4458cc01 (patch) | |
| tree | cff043e8cbfe87cfff5cad9df42949609058ce65 /classes/Pref_Prefs.php | |
| parent | 6b521b5ed14dbc11bf9fecb40a2cd0ce541db9a8 (diff) | |
Replace basic 'isset()' cases with the null coalescing operator.
Diffstat (limited to 'classes/Pref_Prefs.php')
| -rw-r--r-- | classes/Pref_Prefs.php | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/classes/Pref_Prefs.php b/classes/Pref_Prefs.php index 5cbf3c6d1..2bd9ae0bd 100644 --- a/classes/Pref_Prefs.php +++ b/classes/Pref_Prefs.php @@ -1481,17 +1481,11 @@ class Pref_Prefs extends Handler_Protected { } private function _get_short_desc(string $pref_name): string { - if (isset($this->pref_help[$pref_name][0])) { - return $this->pref_help[$pref_name][0]; - } - return ""; + return $this->pref_help[$pref_name][0] ?? ""; } private function _get_help_text(string $pref_name): string { - if (isset($this->pref_help[$pref_name][1])) { - return $this->pref_help[$pref_name][1]; - } - return ""; + return $this->pref_help[$pref_name][1] ?? ""; } private function appPasswordList(): void { |