forked from blallo/rss-bridge
[index] Fixes a bug where requests could result in same cache file names
Previously the cache file name was only build upon bridge parameters. If two bridges don't make use of any parameter this would result into equal file names.
This commit is contained in:
parent
6c4d28c849
commit
85149add61
1 changed files with 6 additions and 6 deletions
12
index.php
12
index.php
|
@ -125,18 +125,18 @@ try {
|
||||||
define('NOPROXY',true);
|
define('NOPROXY',true);
|
||||||
}
|
}
|
||||||
|
|
||||||
$params = $_GET;
|
|
||||||
unset($params['action']);
|
|
||||||
unset($params['bridge']);
|
|
||||||
unset($params['format']);
|
|
||||||
unset($params['_noproxy']);
|
|
||||||
|
|
||||||
// Initialize cache
|
// Initialize cache
|
||||||
$cache = Cache::create('FileCache');
|
$cache = Cache::create('FileCache');
|
||||||
$cache->setPath(CACHE_DIR);
|
$cache->setPath(CACHE_DIR);
|
||||||
$cache->purgeCache(86400); // 24 hours
|
$cache->purgeCache(86400); // 24 hours
|
||||||
$cache->setParameters($params);
|
$cache->setParameters($params);
|
||||||
|
|
||||||
|
$params = $_GET;
|
||||||
|
unset($params['action']);
|
||||||
|
unset($params['bridge']);
|
||||||
|
unset($params['format']);
|
||||||
|
unset($params['_noproxy']);
|
||||||
|
|
||||||
// Load cache & data
|
// Load cache & data
|
||||||
$bridge->setCache($cache);
|
$bridge->setCache($cache);
|
||||||
$bridge->setDatas($params);
|
$bridge->setDatas($params);
|
||||||
|
|
Loading…
Reference in a new issue