]> git.mxchange.org Git - mailer.git/blobdiff - inc/mysql-manager.php
Search for email with regular expression
[mailer.git] / inc / mysql-manager.php
index 51fb3de99dcbfb4adc2dd805352f6d3091c57088..8d64b2201a3864d6a6b26f8df9f52bef048ad7f7 100644 (file)
@@ -451,7 +451,10 @@ function fetchUserData ($value, $column = 'userid') {
        if (!isExtensionActive('user')) {
                // Absent ext-user is really not good
                return false;
-       } // END - if
+       } elseif (is_null($value)) {
+               // This shall never happen, so please report it
+               debug_report_bug(__FUNCTION__, __LINE__, 'value=NULL,column=' . $column . ' - value can never be NULL');
+       }
 
        // If we should look for userid secure&set it here
        if (substr($column, -2, 2) == 'id') {
@@ -787,11 +790,16 @@ function getActionFromModuleWhat ($module, $what) {
                $module = mapModuleToTable($module);
 
                // Guest and member menu is 'main' as the default
-               if (empty($data['action'])) $data['action'] = 'main';
+               if (empty($data['action'])) {
+                       $data['action'] = 'main';
+               } // END - if
 
                // Load from database
                $result = SQL_QUERY_ESC("SELECT `action` FROM `{?_MYSQL_PREFIX?}_%s_menu` WHERE `what`='%s' LIMIT 1",
-                       array($module, $what), __FUNCTION__, __LINE__);
+                       array(
+                               $module,
+                               $what
+                       ), __FUNCTION__, __LINE__);
                if (SQL_NUMROWS($result) == 1) {
                        // Load action value and pray that this one is the right you want... ;-)
                        $data = SQL_FETCHARRAY($result);