includes/mysqli_functions.php: change empty string to quoted NULL strings - as some entries in the database are already empty strings as well and can be easily confused otherwise
includes/mysqli_functions.php: change empty string to quoted NULL strings - as some entries in the database are already empty strings as well and can be easily confused otherwise

--- a/includes/mysqli_functions.php
+++ b/includes/mysqli_functions.php
@@ -103,7 +103,7 @@
 // Used to escape text being put into the database.
 function escapestring($str) {
 	global $dbconnect;
-   if (!is_array($str)) return $dbconnect->real_escape_string(($str===null) ? '' : $str);
+   if (!is_array($str)) return $dbconnect->real_escape_string(($str===null) ? "NULL" : $str);
    return array_map('escapestring', $str);
 }