替换 time() 为 $_SERVER['REQUEST_TIME']

This commit is contained in:
thinkphp
2016-07-03 15:03:10 +08:00
parent a322a28f27
commit ea9682c724
8 changed files with 13 additions and 13 deletions

View File

@@ -62,7 +62,7 @@ class File
if (!file_exists($cacheFile)) {
return false;
}
if (0 != $cacheTime && time() > filemtime($cacheFile) + $cacheTime) {
if (0 != $cacheTime && $_SERVER['REQUEST_TIME'] > filemtime($cacheFile) + $cacheTime) {
// 缓存是否在有效期
return false;
}