mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-09-07 16:37:02 +03:00
Nextcloud don't search if string is less then 2 characters
https://github.com/the-djmaze/snappymail/issues/561#issuecomment-1284191823
This commit is contained in:
parent
a0b4517074
commit
7211869636
1 changed files with 3 additions and 0 deletions
|
|
@ -55,6 +55,9 @@ class Provider implements IProvider
|
||||||
public function search(IUser $user, ISearchQuery $query): SearchResult
|
public function search(IUser $user, ISearchQuery $query): SearchResult
|
||||||
{
|
{
|
||||||
$result = [];
|
$result = [];
|
||||||
|
if (1 < \strlen(\trim($query->getTerm()))) {
|
||||||
|
return SearchResult::complete($this->getName(), $result);
|
||||||
|
}
|
||||||
SnappyMailHelper::startApp();
|
SnappyMailHelper::startApp();
|
||||||
$oActions = \RainLoop\Api::Actions();
|
$oActions = \RainLoop\Api::Actions();
|
||||||
// $oAccount = $oActions->getMainAccountFromToken(false); // Issue: when account switched, wrong email is shown
|
// $oAccount = $oActions->getMainAccountFromToken(false); // Issue: when account switched, wrong email is shown
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue