From: Roland Häder Date: Fri, 15 Jul 2011 22:46:05 +0000 (+0000) Subject: Missing initReferalSystem() call added X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=09fd6484d1eaf735476270c33692f799bc0c9590;p=mailer.git Missing initReferalSystem() call added --- diff --git a/inc/libs/autopurge_functions.php b/inc/libs/autopurge_functions.php index 72d4e0ae7e..12181ed9da 100644 --- a/inc/libs/autopurge_functions.php +++ b/inc/libs/autopurge_functions.php @@ -49,6 +49,7 @@ function addPointsAutoPurge ($userid, $points) { } // END - if // Add points over the ref system directly now + initReferalSystem(); addPointsThroughReferalSystem('autopurge_add', $userid, $points); // Send out mail to user diff --git a/inc/libs/rallye_functions.php b/inc/libs/rallye_functions.php index 8be338a066..c7df107ad4 100644 --- a/inc/libs/rallye_functions.php +++ b/inc/libs/rallye_functions.php @@ -510,6 +510,7 @@ function markReferalRallyesAsExpired ($result) { if ($DATA['points'] > 0) { // Add points directly to user's account + initReferalSystem(); addPointsThroughReferalSystem('rallye_winner:' . $winnerLevel, $userid, $DATA['points']); } // END - if diff --git a/inc/libs/register_functions.php b/inc/libs/register_functions.php index cc3e181578..dc557b742c 100644 --- a/inc/libs/register_functions.php +++ b/inc/libs/register_functions.php @@ -366,6 +366,7 @@ function doRegistration () { updateReferalCounter($userid); // Write his welcome-points + initReferalSystem(); addPointsThroughReferalSystem('register_welcome', $userid, getPointsRegister()); // Write catgories diff --git a/inc/mails/doubler_mails.php b/inc/mails/doubler_mails.php index 7fa1ae34a1..81069f6f7c 100644 --- a/inc/mails/doubler_mails.php +++ b/inc/mails/doubler_mails.php @@ -142,6 +142,7 @@ if (((!SQL_HASZERONUMS($result_total)) && (getConfig('doubler_sent_all') == 'Y') // Exclude webmaster from doubling... if ($content['userid'] != getConfig('doubler_userid')) { // Add points + initReferalSystem(); addPointsThroughReferalSystem(sprintf("doubler_%s", strtolower(getConfig('doubler_send_mode'))), $content['userid'], $content['points']); } // END - if diff --git a/inc/modules/admin/what-del_email.php b/inc/modules/admin/what-del_email.php index d78bcec4d0..de084bb7c3 100644 --- a/inc/modules/admin/what-del_email.php +++ b/inc/modules/admin/what-del_email.php @@ -109,6 +109,7 @@ LIMIT 1", } // END - if // Pay back points + initReferalSystem(); addPointsThroughReferalSystem('mail_deleted', $content['sender'], $totalPoints); // Output message diff --git a/inc/modules/member/what-cash_coupon.php b/inc/modules/member/what-cash_coupon.php index 7c9a24241f..8d384e90ab 100644 --- a/inc/modules/member/what-cash_coupon.php +++ b/inc/modules/member/what-cash_coupon.php @@ -119,6 +119,7 @@ LIMIT 1", } // END - if // Now we just need to book that points on the user's account + initReferalSystem(); addPointsThroughReferalSystem('coupon_cashed', getMemberId(), $content['points']); // Subtract points from member account if the admin has selected one diff --git a/inc/modules/member/what-transfer.php b/inc/modules/member/what-transfer.php index 26abac20f4..c8518df6cb 100644 --- a/inc/modules/member/what-transfer.php +++ b/inc/modules/member/what-transfer.php @@ -161,6 +161,7 @@ switch ($mode) { ), __FILE__, __LINE__); // Add points to account *directly* ... + initReferalSystem(); addPointsThroughReferalSystem('transfer', bigintval(postRequestParameter('to_userid')), bigintval(postRequestParameter('points'))); // ... and add it to current user's used points diff --git a/inc/modules/member/what-wernis.php b/inc/modules/member/what-wernis.php index e00af871a2..d53b7e34ff 100644 --- a/inc/modules/member/what-wernis.php +++ b/inc/modules/member/what-wernis.php @@ -175,6 +175,7 @@ if ((isFormSent()) && (isGetRequestParameterSet('mode'))) { $success = WERNIS_EXECUTE_WITHDRAW(postRequestParameter('wernis_userid'), md5(postRequestParameter('wds66_password')), postRequestParameter('amount')); if ($success === true) { // Add it to this amount + initReferalSystem(); addPointsThroughReferalSystem('wernis_withdraw', getMemberId(), bigintval(postRequestParameter('amount'))); // Update the user data as well.. diff --git a/inc/monthly/monthly_beg.php b/inc/monthly/monthly_beg.php index dfc0eb7863..dcb6daca21 100644 --- a/inc/monthly/monthly_beg.php +++ b/inc/monthly/monthly_beg.php @@ -83,6 +83,7 @@ LIMIT {?beg_ranks?}", __FILE__, __LINE__); // Load our winners... while ($content = SQL_FETCHARRAY($result_main)) { // Add points to user's account directly + initReferalSystem(); addPointsThroughReferalSystem('monthly_beg', $content['userid'], $content['beg_points']); // Load email template and email it away diff --git a/inc/monthly/monthly_bonus.php b/inc/monthly/monthly_bonus.php index ab81c37f9d..5cc27ce3b2 100644 --- a/inc/monthly/monthly_bonus.php +++ b/inc/monthly/monthly_bonus.php @@ -91,6 +91,7 @@ LIMIT {?bonus_ranks?}', __FILE__, __LINE__); // Make sure zero points are not mailed if ($content['points'] > 0) { // Add points to user's account directly + initReferalSystem(); addPointsThroughReferalSystem('monthly_bonus', $content['userid'], $content['points']); // Load email template and email it away diff --git a/inc/pool/pool-user.php b/inc/pool/pool-user.php index 77ab6bc037..bc832f0625 100644 --- a/inc/pool/pool-user.php +++ b/inc/pool/pool-user.php @@ -255,6 +255,7 @@ if (!SQL_HASZERONUMS($result_main)) { if (isValidUserId($userid)) { // User does not exists, pay points back $points = getPaymentPoints($mailData['payment_id']); + initReferalSystem(); addPointsThroughReferalSystem('pool_payback', $mailData['sender_userid'], $points); // Add points together and remove user diff --git a/mailid_top.php b/mailid_top.php index 54f17d5ad3..57c541e972 100644 --- a/mailid_top.php +++ b/mailid_top.php @@ -298,6 +298,7 @@ if ((isValidUserId($userId)) && (($mailId > 0) || ($bonusId > 0)) && (!ifFatalEr loadTemplate($template, false, $content); } elseif (isValidUserId($sender)) { // Wrong image code! So add points to sender's account + initReferalSystem(); addPointsThroughReferalSystem('mailid_payback', $sender, $payment); // Add payment points