mirror of
https://github.com/torrentpier/torrentpier
synced 2025-08-21 13:54:02 -07:00
New cron initialization and minor edits (#619)
* New cron initialization and minor edits Updated the mechanism to check if cron needs to run and made minor improvements to the first run * Adding a warning in the control panel
This commit is contained in:
parent
dd853151c0
commit
e4b6a91909
11 changed files with 37 additions and 11 deletions
|
@ -405,7 +405,12 @@ $userdata =& $user->data;
|
|||
/**
|
||||
* Cron
|
||||
*/
|
||||
if ((empty($_POST) && !defined('IN_ADMIN') && !defined('IN_AJAX') && !file_exists(CRON_RUNNING) && ($bb_cfg['cron_enabled'] || defined('START_CRON'))) || defined('FORCE_CRON')) {
|
||||
if (
|
||||
empty($_POST) &&
|
||||
!defined('IN_ADMIN') && !defined('IN_AJAX') &&
|
||||
!file_exists(CRON_RUNNING) &&
|
||||
(TorrentPier\Helpers\CronHelper::isEnabled() || defined('START_CRON'))
|
||||
) {
|
||||
if (TIMENOW - $bb_cfg['cron_last_check'] > $bb_cfg['cron_check_interval']) {
|
||||
|
||||
/** Update cron_last_check */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue