mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-07 10:41:40 +09:00
Display errors and OK message in webcron result page
This commit is contained in:
parent
e8c03318e4
commit
4ebaa6b0cb
5 changed files with 34 additions and 1 deletions
|
|
@ -33,6 +33,7 @@ else
|
|||
}
|
||||
|
||||
// Get queue configuration set by the administrator.
|
||||
$display_errors = config('queue.display_errors') === false ? false : true;
|
||||
$timeout = (config('queue.interval') ?? 1) * 60;
|
||||
$process_count = config('queue.process_count') ?? 1;
|
||||
|
||||
|
|
@ -41,6 +42,10 @@ if (PHP_SAPI !== 'cli')
|
|||
{
|
||||
ignore_user_abort(true);
|
||||
set_time_limit(max(60, $timeout));
|
||||
if ($display_errors)
|
||||
{
|
||||
ini_set('display_errors', true);
|
||||
}
|
||||
if (Rhymix\Framework\Session::checkStart())
|
||||
{
|
||||
Rhymix\Framework\Session::close();
|
||||
|
|
@ -93,3 +98,9 @@ else
|
|||
{
|
||||
Rhymix\Framework\Queue::process($timeout);
|
||||
}
|
||||
|
||||
// If called over the network, display a simple OK message to indicate success.
|
||||
if (PHP_SAPI !== 'cli')
|
||||
{
|
||||
echo "OK\n";
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue