From 2b30eee91845aa4bb68ccc1e689c2449c98e5dda Mon Sep 17 00:00:00 2001 From: Pablo Zmdl Date: Fri, 27 Sep 2024 09:47:26 +0200 Subject: [PATCH] Fix getting IMAP vendor name In some cases, the array's keys where upper case, and the previous code produced a warning and resulted in an empty string, even though the name was present. --- program/lib/Roundcube/rcube_imap.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/program/lib/Roundcube/rcube_imap.php b/program/lib/Roundcube/rcube_imap.php index acd60e72d73..eb69615c5d0 100644 --- a/program/lib/Roundcube/rcube_imap.php +++ b/program/lib/Roundcube/rcube_imap.php @@ -655,7 +655,7 @@ public function get_vendor() $ident = null; } - $vendor = (string) (!empty($ident) ? $ident['name'] : ''); + $vendor = (string) ($ident['name'] ?? $ident['NAME'] ?? ''); $ident = strtolower($vendor . ' ' . $this->conn->data['GREETING']); $vendors = ['cyrus', 'dovecot', 'uw-imap', 'gimap', 'hmail', 'greenmail'];