]> git.mxchange.org Git - mailer.git/blobdiff - inc/wrapper-functions.php
Some minor rewrites, addPointsAutoPurge() now validates the userid before executing...
[mailer.git] / inc / wrapper-functions.php
index 918ad0a93a039bb7686851c30d9cfb01d4951b89..da04d5ddccea5a9bacc6f1abb70f6daa2f6431a0 100644 (file)
@@ -807,7 +807,7 @@ function initUserData () {
        // User id should not be zero
        if (!isValidUserId(getCurrentUserId())) {
                // Should be always valid
-               debug_report_bug(__FUNCTION__, __LINE__, 'User id is zero.');
+               debug_report_bug(__FUNCTION__, __LINE__, 'Current user id is invalid: ' . getCurrentUserId());
        } // END - if
 
        // Init the user
@@ -819,7 +819,7 @@ function getUserData ($column) {
        // User id should not be zero
        if (!isValidUserId(getCurrentUserId())) {
                // Should be always valid
-               debug_report_bug(__FUNCTION__, __LINE__, 'User id is zero.');
+               debug_report_bug(__FUNCTION__, __LINE__, 'Current user id is invalid: ' . getCurrentUserId());
        } // END - if
 
        // Return the value
@@ -834,7 +834,7 @@ function getUserDataArray () {
        // Is the current userid valid?
        if (!isValidUserId($userid)) {
                // Should be always valid
-               debug_report_bug(__FUNCTION__, __LINE__, 'User id is invalid.');
+               debug_report_bug(__FUNCTION__, __LINE__, 'Current user id is invalid: ' . $userid);
        } // END - if
 
        // Get the whole array if found
@@ -1944,5 +1944,11 @@ function isRawOutputMode () {
        return (getScriptOutputMode() == -1);
 }
 
+// Wrapper to generate a user email link
+function generateWrappedUserEmailLink ($email) {
+       // Just call the inner function
+       return generateEmailLink($email, 'user_data');
+}
+
 // [EOF]
 ?>