]> git.mxchange.org Git - mailer.git/blobdiff - inc/loader/load_cache-modreg.php
Cache class rewritten to better convention
[mailer.git] / inc / loader / load_cache-modreg.php
index 126888ba9bfe80cee68e7fb33c46b0127b6fcedb..25f5652c21adac824290d6b61295870d98c03437 100644 (file)
@@ -38,10 +38,10 @@ if (!defined('__SECURITY')) {
 }
 
 // Next cached table is the module registry (mod_reg)...
-if (($cacheInstance->cache_file("mod_reg")) && ($cacheInstance->ext_version_matches("sql_patches"))) {
+if (($cacheInstance->loadCacheFile("mod_reg")) && ($cacheInstance->extensionVersionMatches("sql_patches"))) {
        // Load cache
        global $cacheArray;
-       $cacheArray['modules'] = $cacheInstance->cache_load();
+       $cacheArray['modules'] = $cacheInstance->getArrayFromCache();
 
        // Rewrite module cache
        $modArray = $cacheArray['modules'];
@@ -66,8 +66,8 @@ if (($cacheInstance->cache_file("mod_reg")) && ($cacheInstance->ext_version_matc
        unset($modArray);
 } elseif (($_CONFIG['cache_modreg'] == "Y") && ($CSS != "1") && ($CSS != "-1")) {
        // Create cache file here
-       $cacheInstance->cache_init("MODULES");
-       $cacheInstance->store_extension_version("sql_patches");
+       $cacheInstance->init("MODULES");
+       $cacheInstance->storeExtensionVersion("sql_patches");
 
        // Load all modules and their data
        if (GET_EXT_VERSION("sql_patches") >= "0.3.6") {
@@ -83,21 +83,18 @@ FROM "._MYSQL_PREFIX."_mod_reg ORDER BY id", __FILE__, __LINE__);
        // Cache all data
        while ($data = SQL_FETCHARRAY($result)) {
                // Add row to cache file
-               $cacheInstance->add_row($data);
+               $cacheInstance->addRow($data);
        } // END - while
 
        // Free memory
        SQL_FREERESULT($result);
 
        // Close the cache
-       $cacheInstance->cache_close();
+       $cacheInstance->finalize();
 
        // Reload the cache
        require(__FILE__);
 }
 
-// Close file
-$cacheInstance->cache_close();
-
 //
 ?>