diff options
| author | 2014-10-09 16:18:26 +0200 | |
|---|---|---|
| committer | 2014-10-09 16:18:26 +0200 | |
| commit | 799bb6e0de68f5dddde53a6ea7178a518d16cbfa (patch) | |
| tree | b8b7b63edae7b9f7553a5df15f2c53c002b26fb5 /app/Controllers/indexController.php | |
| parent | 6dfbc28042c6e18da9c7578ed626064a4d8c7cb3 (diff) | |
| parent | caf98a6468dcea5ae8c38062e4eb527cb3667db9 (diff) | |
Merge branch 'hotfixes' into beta
Conflicts:
CHANGELOG
README.fr.md
README.md
constants.php
Diffstat (limited to 'app/Controllers/indexController.php')
| -rwxr-xr-x | app/Controllers/indexController.php | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/app/Controllers/indexController.php b/app/Controllers/indexController.php index e8e26b142..d3b299f4e 100755 --- a/app/Controllers/indexController.php +++ b/app/Controllers/indexController.php @@ -330,7 +330,8 @@ class FreshRSS_index_Controller extends Minz_ActionController { private static function purgeTokens() { $oldest = time() - 2629744; //1 month //TODO: Use a configuration instead foreach (new DirectoryIterator(DATA_PATH . '/tokens/') as $fileInfo) { - if ($fileInfo->getExtension() === 'txt' && $fileInfo->getMTime() < $oldest) { + $extension = pathinfo($fileInfo->getFilename(), PATHINFO_EXTENSION); + if ($extension === 'txt' && $fileInfo->getMTime() < $oldest) { @unlink($fileInfo->getPathname()); } } |
