X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=inc%2Freset%2Freset_bonus.php;h=d0a57bf66bd104e9f5093b8a67027bdd0ee5c250;hb=f9355ef19837da4e8cb88e0d6c0febf082a1824d;hp=98c2ab506dccf61a0930a78568a114581d83643f;hpb=43885129ac24cee5545a8a5ad51e90aa182fdf46;p=mailer.git diff --git a/inc/reset/reset_bonus.php b/inc/reset/reset_bonus.php index 98c2ab506d..d0a57bf66b 100644 --- a/inc/reset/reset_bonus.php +++ b/inc/reset/reset_bonus.php @@ -32,19 +32,16 @@ ************************************************************************/ // Some security stuff... -if (ereg(basename(__FILE__), $_SERVER['PHP_SELF'])) -{ +if (!defined('__SECURITY')) { $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php"; require($INC); -} - elseif ((!EXT_IS_ACTIVE("bonus")) && (!IS_ADMIN())) -{ +} elseif ((!EXT_IS_ACTIVE("bonus")) && (!IS_ADMIN())) { ADD_FATAL(EXTENSION_PROBLEM_EXT_INACTIVE, "bonus"); return; } // Do not execute when script is in CSS mode or no daily reset -if (($CSS == 1) || (!isBooleanConstantAndTrue('__DAILY_RESET'))) return; +if (($CSS == 1) || (!defined('__DAILY_RESET'))) return; // Reset accounts $result = SQL_QUERY("UPDATE "._MYSQL_PREFIX."_user_data SET turbo_bonus=0, login_bonus=0, bonus_order=0, bonus_stats=0, bonus_ref=0",