mirror of
https://github.com/torrentpier/torrentpier
synced 2025-08-22 14:23:57 -07:00
Опция для фрилича, чистка
Добавляем опцию для возможности орагнизации фрилича; небольшая чистка шаблонизатора; удаление более ненужных проверок в конфиге.
This commit is contained in:
parent
13b22fc62c
commit
ebafe9474a
3 changed files with 298 additions and 497 deletions
|
@ -349,7 +349,7 @@ if ($lp_info && $lp_info['update_time'] < TIMENOW)
|
|||
$up_add = ($lp_info && $uploaded > $lp_info['uploaded']) ? $uploaded - $lp_info['uploaded'] : 0;
|
||||
$down_add = ($lp_info && $downloaded > $lp_info['downloaded']) ? $downloaded - $lp_info['downloaded'] : 0;
|
||||
|
||||
// Gold/Silver releases
|
||||
// Gold / silver releases
|
||||
if ($tr_cfg['gold_silver_enabled'] && $down_add)
|
||||
{
|
||||
if ($tor_type == TOR_TYPE_GOLD)
|
||||
|
@ -363,7 +363,10 @@ if ($tr_cfg['gold_silver_enabled'] && $down_add)
|
|||
}
|
||||
}
|
||||
|
||||
// Insert/update peer info
|
||||
// Freeleech
|
||||
if ($tr_cfg['freeleech'] && $down_add) $down_add = 0;
|
||||
|
||||
// Insert / update peer info
|
||||
$peer_info_updated = false;
|
||||
$update_time = ($stopped) ? 0 : TIMENOW;
|
||||
|
||||
|
|
|
@ -197,6 +197,7 @@ $tr_cfg = array(
|
|||
'gold_silver_enabled' => true,
|
||||
'retracker' => true,
|
||||
'retracker_host' => 'http://retracker.local/announce',
|
||||
'freeleech' => false,
|
||||
);
|
||||
|
||||
$bb_cfg['show_dl_status_in_search'] = true;
|
||||
|
@ -442,12 +443,6 @@ ini_set('display_errors', 0);
|
|||
ini_set('log_errors', 1);
|
||||
ini_set('error_log', LOG_DIR .'php_err.log');
|
||||
|
||||
// Check some variable
|
||||
// Magic quotes
|
||||
if (get_magic_quotes_gpc()) die('Set magic_quotes off');
|
||||
// JSON
|
||||
if (!function_exists('json_encode')) die('Json_encode not installed');
|
||||
|
||||
// Triggers
|
||||
define('BB_ENABLED', TRIGGERS_DIR .'$on');
|
||||
define('BB_DISABLED', TRIGGERS_DIR .'$off');
|
||||
|
|
File diff suppressed because it is too large
Load diff
Loading…
Add table
Add a link
Reference in a new issue