From: Roland Häder Date: Wed, 25 Nov 2009 18:20:26 +0000 (+0000) Subject: Variable conflict solved X-Git-Url: https://git.mxchange.org/?p=mailer.git;a=commitdiff_plain;h=2bf7c8f50b53404be753c4b97ae6d9dffbb404df Variable conflict solved --- diff --git a/inc/mysql-manager.php b/inc/mysql-manager.php index b8f7fed89d..7b13a2a412 100644 --- a/inc/mysql-manager.php +++ b/inc/mysql-manager.php @@ -1944,7 +1944,7 @@ function generateReceiverList ($cat, $receiver, $mode = '') { } // Get timestamp for given stats type and data -function getTimestampFromUserStats ($type, $data, $userid = '0') { +function getTimestampFromUserStats ($statsType, $statsData, $userid = '0') { // Default timestamp is zero $data['inserted'] = '0'; @@ -1971,8 +1971,8 @@ WHERE LIMIT 1", array( bigintval($userid), - $type, - $data + $statsType, + $statsData ), __FUNCTION__, __LINE__); // Is the entry there? @@ -1989,7 +1989,7 @@ LIMIT 1", } // Inserts user stats -function insertUserStatsRecord ($userid, $type, $data) { +function insertUserStatsRecord ($userid, $statsType, $statsData) { // Is the extension installed and updated? if ((!isExtensionActive('sql_patches')) || (isExtensionOlder('sql_patches', '0.5.6'))) { // Return zero here @@ -1997,13 +1997,13 @@ function insertUserStatsRecord ($userid, $type, $data) { } // END - if // Does it exist? - if ((!getTimestampFromUserStats($type, $data, $userid)) && (!is_array($data))) { + if ((!getTimestampFromUserStats($statsType, $statsData, $userid)) && (!is_array($statsData))) { // Then insert it! SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_user_stats_data` (`userid`,`stats_type`,`stats_data`) VALUES (%s,'%s','%s')", - array(bigintval($userid), $type, $data), __FUNCTION__, __LINE__); - } elseif (is_array($data)) { + array(bigintval($userid), $statsType, $statsData), __FUNCTION__, __LINE__); + } elseif (is_array($statsData)) { // Invalid data! - logDebugMessage(__FUNCTION__, __LINE__, "userid={$userid},type={$type},data={".gettype($data).": Invalid statistics data type!"); + logDebugMessage(__FUNCTION__, __LINE__, "userid={$userid},type={$statsType},data={".gettype($statsData).": Invalid statistics data type!"); } }