dont start testjob, if user has no email address set

This commit is contained in:
Ralf Becker 2010-02-03 03:40:32 +00:00
parent 392900daaf
commit 8ad9d0cde5

View File

@ -56,7 +56,11 @@ class uiasyncservice
if ($_POST['test'])
{
if (!$async->set_timer($times,'test','admin.uiasyncservice.test',$GLOBALS['egw_info']['user']['email']))
if (strpos($GLOBALS['egw_info']['user']['email'],'@') === false)
{
echo '<p><b>'.lang("You have no email address for your user set !!!")."</b></p>\n";
}
elseif (!$async->set_timer($times,'test','admin.uiasyncservice.test',$GLOBALS['egw_info']['user']['email']))
{
echo '<p><b>'.lang("Error setting timer, wrong syntax or maybe there's one already running !!!")."</b></p>\n";
}