Go to the source code of this file.
◆ sanitycheck_hook_cron()
sanitycheck_hook_cron |
( |
& |
$croninfo | ) |
|
Hook to run a cron job.
- Parameters
-
Definition at line 7 of file hook_cron.php.
8{
9 assert('is_array($croninfo)');
10 assert('array_key_exists("summary", $croninfo)');
11 assert('array_key_exists("tag", $croninfo)');
12
14
15 try {
17
18 $cronTag = $sconfig->getString('cron_tag', null);
19 if ($cronTag ===
null || $cronTag !==
$croninfo[
'tag']) {
20 return;
21 }
22
28 );
29
31
34 $croninfo[
'summary'][] =
'Sanitycheck error: ' . $err;
35 }
36 }
37
38 } catch (Exception $e) {
39 $croninfo[
'summary'][] =
'Error executing sanity check: ' . $e->getMessage();
40 }
41}
static callHooks($hook, &$data=null)
Call a hook in all enabled modules.
static getOptionalConfig($filename='config.php', $configSet='simplesaml')
Load a configuration file from a configuration set.
References $croninfo, $errors, $hookinfo, $info, SimpleSAML\Module\callHooks(), SimpleSAML_Configuration\getOptionalConfig(), and SimpleSAML\Logger\info().