]> git.mxchange.org Git - mailer.git/blobdiff - inc/wrapper-functions.php
Opps ... :(
[mailer.git] / inc / wrapper-functions.php
index 1520f1191589d24b8c4d5c1f94ee645459b0c6af..ce97e2fc257d6817891f654563e482dd76c5e08d 100644 (file)
@@ -2336,7 +2336,7 @@ function getTotalPoints ($userid) {
        // Do we have cache?
        if (!isset($GLOBALS[__FUNCTION__][$userid])) {
                // Determine it
-               $GLOBALS[__FUNCTION__][$userid] = countSumTotalData($userid, 'user_points', 'points') - countSumTotalData($userid, 'user_data', 'used_points');
+               $GLOBALS[__FUNCTION__][$userid] = countSumTotalData($userid, 'user_points', 'points') - countSumTotalData($userid, 'user_points', 'order_points') - countSumTotalData($userid, 'user_data', 'used_points');
        } // END - if
 
        // Return cache