X-Git-Url: https://git.mxchange.org/?p=mailer.git;a=blobdiff_plain;f=inc%2Flibs%2Fuser_functions.php;h=af1e552320412fe79659b800254069069e156db7;hp=61ae0ea3cc8ddeb615cfd35589eba711c7a2ac83;hb=e45e218c4f629ec63f0788cab231bfc88b3fa46e;hpb=9f5f55cd28eebd7b389c13f7c3be500ff43d0a28;ds=sidebyside diff --git a/inc/libs/user_functions.php b/inc/libs/user_functions.php index 61ae0ea3cc..af1e552320 100644 --- a/inc/libs/user_functions.php +++ b/inc/libs/user_functions.php @@ -228,7 +228,7 @@ function determineRandomReferalId () { $refid = '0'; // Is the extension version fine? - if (getExtensionVersion('user') >= '0.3.4') { + if (isExtensionInstalledAndNewer('user', '0.3.4')) { // Get all user ids $totalUsers = countSumTotalData('CONFIRMED', 'user_data', 'userid', 'status', true, " AND `rand_confirmed` >= ".getConfig('user_min_confirmed').""); @@ -331,7 +331,7 @@ function doUserLogin ($userid, $passwd, $successUrl = '', $errorUrl = 'modules.p $GLOBALS['bonus_payed'] = true; // Subtract login bonus from userid's account or jackpot - if ((getExtensionVersion('bonus') >= '0.3.5') && (getConfig('bonus_mode') != 'ADD')) handleBonusPoints('login_bonus'); + if ((isExtensionInstalledAndNewer('bonus', '0.3.5')) && (getConfig('bonus_mode') != 'ADD')) handleBonusPoints('login_bonus'); } // END - if // @TODO Make this filter working: $URL = runFilterChain('do_login', array('content' => $content, 'addon' => $ADDON)); @@ -368,7 +368,7 @@ function doUserLogin ($userid, $passwd, $successUrl = '', $errorUrl = 'modules.p // Cookies not setable! $errorCode = getCode('COOKIES_DISABLED'); } - } elseif (getExtensionVersion('sql_patches') >= '0.6.1') { + } elseif (isExtensionInstalledAndNewer('sql_patches', '0.6.1')) { // Update failture counter SQL_QUERY_ESC("UPDATE `{?_MYSQL_PREFIX?}_user_data` SET `login_failures`=`login_failures`+1,`last_failure`=NOW() WHERE `userid`=%s LIMIT 1", array($userid), __FUNCTION__, __LINE__);