mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-07-13 03:27:39 +03:00
Small fixes
This commit is contained in:
parent
6266b50c03
commit
d5c68d1761
2 changed files with 23 additions and 11 deletions
|
|
@ -292,7 +292,7 @@ class Actions
|
|||
{
|
||||
$this->KeenIO('Install');
|
||||
}
|
||||
catch (\Exception $oException) {}
|
||||
catch (\Exception $oException) { unset($oException); }
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -5767,20 +5767,27 @@ class Actions
|
|||
|
||||
if ($iLimit > \count($aResult) && 0 < \strlen($sQuery))
|
||||
{
|
||||
// Address Book
|
||||
$oAddressBookProvider = $this->AddressBookProvider($oAccount);
|
||||
if ($oAddressBookProvider && $oAddressBookProvider->IsActive())
|
||||
try
|
||||
{
|
||||
$aSuggestions = $oAddressBookProvider->GetSuggestions($oAccount->ParentEmailHelper(), $sQuery, $iLimit);
|
||||
if (0 === \count($aResult))
|
||||
// Address Book
|
||||
$oAddressBookProvider = $this->AddressBookProvider($oAccount);
|
||||
if ($oAddressBookProvider && $oAddressBookProvider->IsActive())
|
||||
{
|
||||
$aResult = $aSuggestions;
|
||||
}
|
||||
else
|
||||
{
|
||||
$aResult = \array_merge($aResult, $aSuggestions);
|
||||
$aSuggestions = $oAddressBookProvider->GetSuggestions($oAccount->ParentEmailHelper(), $sQuery, $iLimit);
|
||||
if (0 === \count($aResult))
|
||||
{
|
||||
$aResult = $aSuggestions;
|
||||
}
|
||||
else
|
||||
{
|
||||
$aResult = \array_merge($aResult, $aSuggestions);
|
||||
}
|
||||
}
|
||||
}
|
||||
catch (\Exception $oException)
|
||||
{
|
||||
$this->Logger()->WriteException($oException);
|
||||
}
|
||||
}
|
||||
|
||||
if ($iLimit < \count($aResult))
|
||||
|
|
|
|||
|
|
@ -72,6 +72,11 @@ abstract class PdoAbstract
|
|||
throw new \Exception('Unknown PDO SQL connection type');
|
||||
}
|
||||
|
||||
if (empty($sDsn))
|
||||
{
|
||||
throw new \Exception('Empty PDO DSN configuration');
|
||||
}
|
||||
|
||||
$this->sDbType = $sType;
|
||||
|
||||
$oPdo = false;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue