]> git.mxchange.org Git - mailer.git/commitdiff
insertUserStatsRecord() was commented out, but still the status (true/false) is being...
authorRoland Häder <roland@mxchange.org>
Thu, 28 Jul 2011 23:56:02 +0000 (23:56 +0000)
committerRoland Häder <roland@mxchange.org>
Thu, 28 Jul 2011 23:56:02 +0000 (23:56 +0000)
inc/libs/user_functions.php
mailid_top.php

index 029ab472ff5fbdb2c3f837c63051bc233ed405b2..488e8f6f4f10143a3c88904bf0f365581f068dd8 100644 (file)
@@ -524,6 +524,9 @@ function insertUserStatsRecord ($userid, $statsType, $statsData) {
                return false;
        } // END - if
 
+       // Default is not working
+       $return = false;
+
        // Does it exist?
        if ((!getEpocheTimeFromUserStats($statsType, $statsData, $userid)) && (!is_array($statsData))) {
                // Then insert it!
@@ -533,10 +536,16 @@ function insertUserStatsRecord ($userid, $statsType, $statsData) {
                                $statsType,
                                $statsData
                        ), __FUNCTION__, __LINE__);
+
+               // Does it have worked?
+               $return = (!SQL_HASZEROAFFECTED());
        } elseif (is_array($statsData)) {
                // Invalid data!
                logDebugMessage(__FUNCTION__, __LINE__, 'userid=' . $userid . ',type=' . $statsType . ',data=' . gettype($statsData) . ': Invalid statistics data type!');
        }
+
+       // Return status
+       return $return;
 }
 
 // Confirms a user account
index dbd32df25c8099ee7a8df4d3981f743b6e01c80b..40ef802d4167751fd426cb85f85f11aeae111050 100644 (file)
@@ -239,7 +239,7 @@ if ((isValidUserId($userId)) && (($mailId > 0) || ($bonusId > 0)) && (!ifFatalEr
                                                                        } // END - if
 
                                                                        // Insert stats record
-                                                                       //insertUserStatsRecord($userId, $type, $stats_data);
+                                                                       insertUserStatsRecord($userId, $type, $stats_data);
 
                                                                        // Right code entered?
                                                                        if (bigintval(postRequestParameter('gfx_check')) == $realCode) {