X-Git-Url: https://git.mxchange.org/?p=mailer.git;a=blobdiff_plain;f=inc%2Floader%2Fload_cache-revision.php;h=e71891f83354cb67ccd2b8c3a52da2d8dc133525;hp=f9e9ec11003ed9b3ed4680f3e29465ac9bf913ba;hb=263a089d8a499e0e26d0af9e7aa7639f88b8ca60;hpb=a090e351c49fe021fb3064325694da03402332e0 diff --git a/inc/loader/load_cache-revision.php b/inc/loader/load_cache-revision.php index f9e9ec1100..e71891f833 100644 --- a/inc/loader/load_cache-revision.php +++ b/inc/loader/load_cache-revision.php @@ -1,7 +1,7 @@ loadCacheFile('revision', true))) { +if (($GLOBALS['cache_instance']->loadCacheFile('revision'))) { // Load revision from cache $GLOBALS['cache_array']['revision'] = $GLOBALS['cache_instance']->getArrayFromCache(); -} elseif (($GLOBALS['output_mode'] != '1') && ($GLOBALS['output_mode'] != '-1')) { +} elseif ((getOutputMode() != 1)) { // Create cache file here - $GLOBALS['cache_instance']->init('revision'); + $GLOBALS['cache_instance']->init(); // add the new RevInfos in and saves it to the cache - $GLOBALS['cache_instance']->addRow(getAkt_vers()); + $GLOBALS['cache_instance']->addRow(getArrayFromActualVersion()); // Close the cache $GLOBALS['cache_instance']->finalize(); - // Include loader again - require(__FILE__); + // Generate FQFN for old revision file + $FQFN = sprintf("%s/.revision", getConfig('CACHE_PATH')); + + // Is it there? + if (isFileReadable($FQFN)) { + // Then remove it + removeFile($FQFN); + } // END - if } -// +// [EOF] ?>