-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathJob.php
More file actions
24 lines (21 loc) · 788 Bytes
/
Copy pathJob.php
File metadata and controls
24 lines (21 loc) · 788 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
<?php
namespace FreePBX\modules\Repeatcaller;
use FreePBX;
use FreePBX\Job\TaskInterface;
use Symfony\Component\Console\Input\InputInterface;
use Symfony\Component\Console\Output\OutputInterface;
use Throwable;
class Job implements TaskInterface {
public static function run(InputInterface $input, OutputInterface $output) {
try {
return FreePBX::Repeatcaller()->runBackgroundMonitor($output);
} catch (Throwable $e) {
try {
FreePBX::Log()->error('repeatcaller job: unhandled scheduler exception: ' . $e->getMessage());
} catch (Throwable $ignored) {
error_log('repeatcaller job: unhandled scheduler exception: ' . $e->getMessage());
}
return false;
}
}
}