do not try to push notifications for api.queue requests

This commit is contained in:
Hadi Nategh 2020-05-22 10:16:59 +02:00
parent 4a4f2a03b9
commit 8d022c5908
2 changed files with 5 additions and 3 deletions

View File

@ -157,8 +157,9 @@ class Url extends Etemplate\Widget
public static function ajax_contact($_email)
{
$email = \EGroupware\Api\Mail::stripRFC822Addresses(array($_email));
$response = \EGroupware\Api\Json\Response::get();
$result = $GLOBALS['egw']->contacts->search(array('contact_email'=>$email[0], 'contact_email_home' => $email[0]), array('email','email_home'),
'', '', '', false, 'OR', false);
\EGroupware\Api\Json\Response::data($result ? true : false);
$response->data($result ? true : false);
}
}

View File

@ -103,6 +103,8 @@ class Request
{
$this->handleRequest($menuaction, $parameters);
}
// check if we have push notifications, if notifications app available
if (class_exists('notifications_push')) notifications_push::get();
}
/**
@ -191,7 +193,6 @@ class Request
call_user_func_array(array($ajaxClass, $functionName),
Api\Translation::convert($parameters, 'utf-8'));
// check if we have push notifications, if notifications app available
if (class_exists('notifications_push')) notifications_push::get();
}
}