From 5e416aca5578326993da80de0eaf669612edb18d Mon Sep 17 00:00:00 2001 From: ralf Date: Tue, 14 Nov 2023 15:50:36 +0200 Subject: [PATCH] fix SQL error creating new mail-user, if username contains non-ascii chars --- api/src/Mail/Smtp/Sql.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/api/src/Mail/Smtp/Sql.php b/api/src/Mail/Smtp/Sql.php index 85eef0f226..dcce7c3a8a 100644 --- a/api/src/Mail/Smtp/Sql.php +++ b/api/src/Mail/Smtp/Sql.php @@ -320,11 +320,11 @@ class Sql extends Mail\Smtp // set mailbox address, if not yet set elseif (!$_forwarding_only && empty($mailbox)) { - $flags[self::TYPE_MAILBOX] = $this->mailbox_addr(array( + $flags[self::TYPE_MAILBOX] = Api\Translation::to_ascii($this->mailbox_addr(array( 'account_id' => $_uidnumber, 'account_lid' => $this->accounts->id2name($_uidnumber, 'account_lid'), 'account_email' => $_mailLocalAddress, - )); + ))); } // store all new values foreach($flags+array(