cleanup in cli

This commit is contained in:
xiaomlove
2021-05-31 21:04:49 +08:00
parent f79c0a22bc
commit a6f2419c5e
4 changed files with 38 additions and 8 deletions

View File

@@ -4,9 +4,8 @@ if(!defined('IN_TRACKER'))
die('Hacking attempt!');
function printProgress($msg) {
echo $msg.'...done<br />';
ob_flush();
flush();
$br = php_sapi_name() == 'cli' ? "\n" : "<br />";
echo sprintf("[%s] %s ... done!%s", date('Y-m-d H:i:s'), $msg, $br);
}
function torrent_promotion_expire($days, $type = 2, $targettype = 1){