X-Git-Url: https://git.mxchange.org/?p=mailer.git;a=blobdiff_plain;f=inc%2Fwrapper-functions.php;h=191b6164cac929610548a35e7c06891e0eb25a78;hp=20169be5dd324ab3e6199474f65343fd935370df;hb=eb3e924768678719afc1bfaffb69354c407daa5b;hpb=e5dffd4249c97200cbad02f3f4eaf5c373fdb89a diff --git a/inc/wrapper-functions.php b/inc/wrapper-functions.php index 20169be5dd..191b6164ca 100644 --- a/inc/wrapper-functions.php +++ b/inc/wrapper-functions.php @@ -527,7 +527,7 @@ function isDebugBuildMailsEnabled () { } // Checks whether the cache instance is valid -function isCacheInstanceValid () { +function isValidCacheInstance () { // Is there cache? if (!isset($GLOBALS[__FUNCTION__])) { // Determine it @@ -829,7 +829,7 @@ function isBlockModeEnabled () { // Abort if not set if (!isset($GLOBALS['__block_mode'])) { // Needs to be fixed - reportBug(__FUNCTION__, __LINE__, 'Block_mode is not set.'); + reportBug(__FUNCTION__, __LINE__, '__block_mode is not set.'); } // END - if // Return it @@ -1085,7 +1085,7 @@ function getUserDataArray () { // Checks if the user data is valid, this may indicate that the user has logged // in, but you should use isMember() if you want to find that out. -function isUserDataValid () { +function isValidUserData () { // User id should not be zero so abort here if (!isCurrentUserIdSet()) { // Debug message, may be noisy @@ -1175,7 +1175,7 @@ function isDebugTemplateCacheEnabled () { // Is there cache? if (!isset($GLOBALS[__FUNCTION__])) { // Determine it - $GLOBALS[__FUNCTION__] = (getConfig('DEBUG_TEMPLATE_CACHE') == 'Y'); + $GLOBALS[__FUNCTION__] = ((isConfigEntrySet('DEBUG_TEMPLATE_CACHE')) && (getConfig('DEBUG_TEMPLATE_CACHE') == 'Y')); } // END - if // Return cache @@ -1594,7 +1594,7 @@ function isTitleDecorationEnabled () { // Is there cache? if (!isset($GLOBALS[__FUNCTION__])) { // Just check it - $GLOBALS[__FUNCTION__] = (getConfig('enable_title_deco') == 'Y'); + $GLOBALS[__FUNCTION__] = ((isExtensionInstalledAndNewer('sql_patches', '0.1.6')) && (isConfigEntrySet('enable_title_deco')) && (getConfig('enable_title_deco') == 'Y')); } // END - if // Return cache @@ -1654,7 +1654,7 @@ function isDisplayDebugSqlEnabled () { // Is there cache? if (!isset($GLOBALS[__FUNCTION__])) { // Determine it - $GLOBALS[__FUNCTION__] = ((isExtensionInstalledAndNewer('other', '0.2.2')) && (getDisplayDebugSqls() == 'Y')); + $GLOBALS[__FUNCTION__] = ((isExtensionInstalledAndNewer('other', '0.2.2')) && (isConfigEntrySet('display_debug_sql')) && (getDisplayDebugSqls() == 'Y')); } // END - if // Return cache @@ -1666,7 +1666,7 @@ function isModuleTitleEnabled () { // Is there cache? if (!isset($GLOBALS[__FUNCTION__])) { // Determine it - $GLOBALS[__FUNCTION__] = (getConfig('enable_mod_title') == 'Y'); + $GLOBALS[__FUNCTION__] = ((isExtensionInstalledAndNewer('sql_patches', '0.1.6')) && (isConfigEntrySet('enable_mod_title')) && (getConfig('enable_mod_title') == 'Y')); } // END - if // Return cache @@ -1678,7 +1678,7 @@ function isWhatTitleEnabled () { // Is there cache? if (!isset($GLOBALS[__FUNCTION__])) { // Determine it - $GLOBALS[__FUNCTION__] = (getConfig('enable_what_title') == 'Y'); + $GLOBALS[__FUNCTION__] = ((isExtensionInstalledAndNewer('sql_patches', '0.1.6')) && (isConfigEntrySet('enable_what_title')) && (getConfig('enable_what_title') == 'Y')); } // END - if // Return cache @@ -1714,7 +1714,7 @@ function isAdminNotificationEnabled () { // Is there cache? if (!isset($GLOBALS[__FUNCTION__])) { // Determine it - $GLOBALS[__FUNCTION__] = ((isExtensionInstalledAndNewer('other', '0.3.0')) && (getAdminNotify() == 'Y')); + $GLOBALS[__FUNCTION__] = ((isExtensionInstalledAndNewer('other', '0.3.0')) && (isConfigEntrySet('admin_notify')) && (getAdminNotify() == 'Y')); } // END - if // Return cache @@ -1726,7 +1726,7 @@ function isRandomReferralIdEnabled () { // Is there cache? if (!isset($GLOBALS[__FUNCTION__])) { // Determine it - $GLOBALS[__FUNCTION__] = ((isExtensionInstalledAndNewer('user', '0.3.4')) && (getSelectUserZeroRefid() == 'Y')); + $GLOBALS[__FUNCTION__] = ((isExtensionInstalledAndNewer('user', '0.3.4')) && (isConfigEntrySet('select_user_zero_refid')) && (getSelectUserZeroRefid() == 'Y')); } // END - if // Return cache @@ -2601,7 +2601,7 @@ function isDisplayHomeInIndexEnabled () { // Is the cache entry set? if (!isset($GLOBALS[__FUNCTION__])) { // No, so determine it - $GLOBALS[__FUNCTION__] = (getDisplayHomeInIndex() == 'Y'); + $GLOBALS[__FUNCTION__] = ((isExtensionInstalledAndNewer('sql_patches', '0.8.3')) && (isConfigEntrySet('display_home_in_index')) && (getDisplayHomeInIndex() == 'Y')); } // END - if // Return cached entry @@ -2625,7 +2625,7 @@ function isShowPointsUnconfirmedEnabled () { // Is the cache entry set? if (!isset($GLOBALS[__FUNCTION__])) { // No, so determine it - $GLOBALS[__FUNCTION__] = (getShowPointsUnconfirmed() == 'Y'); + $GLOBALS[__FUNCTION__] = ((isExtensionInstalledAndNewer('sql_patches', '0.5.5')) && (isConfigEntrySet('show_points_unconfirmed')) && (getShowPointsUnconfirmed() == 'Y')); } // END - if // Return cached entry @@ -2649,7 +2649,7 @@ function isYoureHereEnabled () { // Is the cache entry set? if (!isset($GLOBALS[__FUNCTION__])) { // No, so determine it - $GLOBALS[__FUNCTION__] = (getYoureHere() == 'Y'); + $GLOBALS[__FUNCTION__] = ((isExtensionInstalledAndNewer('sql_patches', '0.2.3')) && (isConfigEntrySet('youre_here')) && (getYoureHere() == 'Y')); } // END - if // Return cached entry @@ -2673,7 +2673,7 @@ function isShowTimingsEnabled () { // Is the cache entry set? if (!isset($GLOBALS[__FUNCTION__])) { // No, so determine it - $GLOBALS[__FUNCTION__] = (getShowTimings() == 'Y'); + $GLOBALS[__FUNCTION__] = ((isExtensionInstalledAndNewer('sql_patches', '0.4.1')) && (isConfigEntrySet('show_timings')) && (getShowTimings() == 'Y')); } // END - if // Return cached entry @@ -2910,7 +2910,7 @@ function isDirectPaymentEnabled () { // Is there cache? if (!isset($GLOBALS[__FUNCTION__])) { // Determine it - $GLOBALS[__FUNCTION__] = (getConfig('allow_direct_pay') == 'Y'); + $GLOBALS[__FUNCTION__] = ((isConfigEntrySet('allow_direct_pay')) && (getConfig('allow_direct_pay') == 'Y')); } // END - if // Return cache @@ -2922,7 +2922,7 @@ function isAdminMenuJavascriptEnabled () { // Is there cache? if (!isset($GLOBALS[__FUNCTION__])) { // Determine it - $GLOBALS[__FUNCTION__] = ((isExtensionInstalledAndNewer('sql_patches', '0.8.7')) && (getAdminMenuJavaScript() == 'Y')); + $GLOBALS[__FUNCTION__] = ((isExtensionInstalledAndNewer('sql_patches', '0.8.7')) && (isConfigEntrySet('admin_menu_javascript')) && (getAdminMenuJavaScript() == 'Y')); } // END - if // Return cache