mirror of
https://github.com/lkddi/nexusphp.git
synced 2026-04-24 12:07:23 +08:00
fix trafic upload error when downloaded = 0
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
<?php
|
<?php
|
||||||
defined('VERSION_NUMBER') || define('VERSION_NUMBER', '1.7.33');
|
defined('VERSION_NUMBER') || define('VERSION_NUMBER', '1.7.33');
|
||||||
defined('RELEASE_DATE') || define('RELEASE_DATE', '2022-12-08');
|
defined('RELEASE_DATE') || define('RELEASE_DATE', '2022-12-14');
|
||||||
defined('IN_TRACKER') || define('IN_TRACKER', false);
|
defined('IN_TRACKER') || define('IN_TRACKER', false);
|
||||||
defined('PROJECTNAME') || define("PROJECTNAME","NexusPHP");
|
defined('PROJECTNAME') || define("PROJECTNAME","NexusPHP");
|
||||||
defined('NEXUSPHPURL') || define("NEXUSPHPURL","https://nexusphp.org");
|
defined('NEXUSPHPURL') || define("NEXUSPHPURL","https://nexusphp.org");
|
||||||
|
|||||||
+10
-3
@@ -523,9 +523,16 @@ if ($action == "exchange") {
|
|||||||
}
|
}
|
||||||
//=== trade for upload
|
//=== trade for upload
|
||||||
if($art == "traffic") {
|
if($art == "traffic") {
|
||||||
if ($CURUSER['uploaded'] > $dlamountlimit_bonus * 1073741824)//uploaded amount reach limit
|
if ($CURUSER['uploaded'] > $dlamountlimit_bonus * 1073741824) {
|
||||||
$ratio = $CURUSER['uploaded']/$CURUSER['downloaded'];
|
//uploaded amount reach limit
|
||||||
else $ratio = 0;
|
if ($CURUSER['downloaded'] > 0) {
|
||||||
|
$ratio = $CURUSER['uploaded']/$CURUSER['downloaded'];
|
||||||
|
} else {
|
||||||
|
$ratio = PHP_INT_MAX;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
$ratio = 0;
|
||||||
|
}
|
||||||
if ($ratiolimit_bonus > 0 && $ratio > $ratiolimit_bonus)
|
if ($ratiolimit_bonus > 0 && $ratio > $ratiolimit_bonus)
|
||||||
die($lang_mybonus['text_cheat_alert']);
|
die($lang_mybonus['text_cheat_alert']);
|
||||||
else {
|
else {
|
||||||
|
|||||||
Reference in New Issue
Block a user