]> git.mxchange.org Git - mailer.git/blobdiff - inc/mysql-manager.php
More '0' to NULL and fix for failing extension deprecation if no admin is logged in
[mailer.git] / inc / mysql-manager.php
index 8a8e3107097c2312264d057065bb92556227670c..a9733b4ec1489db3e08ea1f4dbba5cdd434320e9 100644 (file)
@@ -1691,12 +1691,12 @@ function reduceRecipientReceivedMails ($column, $id, $count) {
 }
 
 // Creates a new task
-function createNewTask ($subject, $notes, $taskType, $userid = NULL, $adminId = '0', $strip = true) {
+function createNewTask ($subject, $notes, $taskType, $userid = NULL, $adminId = NULL, $strip = true) {
        // Insert the task data into the database
        SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_task_system` (`assigned_admin`,`userid`,`status`,`task_type`,`subject`,`text`,`task_created`) VALUES (%s,%s,'NEW','%s','%s','%s', UNIX_TIMESTAMP())",
                array(
-                       $adminId,
-                       $userid,
+                       makeZeroToNull($adminId),
+                       makeZeroToNull($userid),
                        $taskType,
                        $subject,
                        $notes