This commit is contained in:
the-djmaze 2024-02-15 23:45:43 +01:00
parent e02cb38974
commit 5a69d1e241

View file

@ -59,21 +59,25 @@ trait Folders
$oNamespaces = $this->ImapClient()->GetNamespaces();
if ($oNamespaces) {
if (isset($oNamespaces->aOtherUsers[0])) {
if (isset($oNamespaces->aOtherUsers[0])) try {
$oCollection = $this->MailClient()->Folders($oNamespaces->aOtherUsers[0]['prefix'], '*', $HideUnsubscribed);
if ($oCollection) {
foreach ($oCollection as $oFolder) {
$oFolderCollection[$oFolder->FullName] = $oFolder;
}
}
} catch (\Throwable $e) {
// https://github.com/the-djmaze/snappymail/issues/1438
}
if (isset($oNamespaces->aShared[0])) {
if (isset($oNamespaces->aShared[0])) try {
$oCollection = $this->MailClient()->Folders($oNamespaces->aShared[0]['prefix'], '*', $HideUnsubscribed);
if ($oCollection) {
foreach ($oCollection as $oFolder) {
$oFolderCollection[$oFolder->FullName] = $oFolder;
}
}
} catch (\Throwable $e) {
// https://github.com/the-djmaze/snappymail/issues/1438
}
}