Move fileinfo cache to fileinfo directory

This commit is contained in:
eraseyourknees 2022-09-11 03:46:54 +02:00
parent 980863c20e
commit 6d5f3a80f9

View File

@ -34,7 +34,7 @@ function uupApiPrivateGetFromFileinfo($sortByDate = 0) {
consoleLogger('Parsing database info...');
$cacheFile = 'cache/fileinfo_v2.json';
$cacheFile = 'fileinfo/?cache.json';
$cacheV2Version = 1;
$database = @file_get_contents($cacheFile);
@ -57,7 +57,9 @@ function uupApiPrivateGetFromFileinfo($sortByDate = 0) {
$newDb = array();
$builds = array();
foreach($files as $file) {
if($file == '.' || $file == '..') continue;
if($file == '.' || $file == '..' || $file == '?cache.json')
continue;
$uuid = preg_replace('/\.json$/', '', $file);
if(!isset($database[$uuid])) {