mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-18 15:33:15 +00:00
reverts
This commit is contained in:
@@ -54,10 +54,6 @@ class task_Scheduler
|
||||
*/
|
||||
public function run()
|
||||
{
|
||||
if (function_exists('pcntl_signal')) {
|
||||
// avoid <defunct> php when a task ends
|
||||
pcntl_signal(SIGCHLD, SIG_IGN);
|
||||
}
|
||||
|
||||
$appbox = appbox::get_instance(\bootstrap::getCore());
|
||||
$registry = $appbox->get_registry();
|
||||
@@ -76,6 +72,9 @@ class task_Scheduler
|
||||
}
|
||||
|
||||
if (function_exists('pcntl_fork')) {
|
||||
// avoid <defunct> php when a task ends
|
||||
pcntl_signal(SIGCHLD, SIG_IGN);
|
||||
|
||||
$this->method = self::METHOD_FORK;
|
||||
}
|
||||
|
||||
|
@@ -321,7 +321,7 @@ abstract class task_abstract
|
||||
|
||||
abstract public function help();
|
||||
|
||||
public function __construct($taskid, Logger $logger = NULL)
|
||||
public function __construct($taskid, Logger $logger)
|
||||
{
|
||||
$this->logger = $logger;
|
||||
|
||||
|
@@ -41,9 +41,9 @@ class task_manager
|
||||
|
||||
$core = \bootstrap::getCore();
|
||||
|
||||
// if ( ! $logger) {
|
||||
// $logger = $core['monolog'];
|
||||
// }
|
||||
if ( ! $logger) {
|
||||
$logger = $core['monolog'];
|
||||
}
|
||||
|
||||
$sql = "SELECT task2.* FROM task2 ORDER BY task_id ASC";
|
||||
$stmt = $this->appbox->get_connection()->prepare($sql);
|
||||
@@ -81,9 +81,9 @@ class task_manager
|
||||
{
|
||||
$core = \bootstrap::getCore();
|
||||
|
||||
// if ( ! $logger) {
|
||||
// $logger = $core['monolog'];
|
||||
// }
|
||||
if ( ! $logger) {
|
||||
$logger = $core['monolog'];
|
||||
}
|
||||
|
||||
$tasks = $this->getTasks(false, $logger);
|
||||
|
||||
|
Reference in New Issue
Block a user