aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB
diff options
context:
space:
mode:
authorTristan Darricau <tristan.darricau@sensiolabs.com>2016-03-09 21:53:14 +0100
committerTristan Darricau <tristan.darricau@sensiolabs.com>2016-03-09 21:53:14 +0100
commit61e0247f220c9e523e566d517dfa8dc22cc95513 (patch)
treead42bd23c7af29ebbc5a8abc82c7b1afefc0f19f /phpBB
parent5e84d47a0326e9d7a83809b9fe5278fb7b9796b5 (diff)
parentdb1b73a3f4c8a7c11b493c930a080c3dfafb086b (diff)
downloadforums-61e0247f220c9e523e566d517dfa8dc22cc95513.tar
forums-61e0247f220c9e523e566d517dfa8dc22cc95513.tar.gz
forums-61e0247f220c9e523e566d517dfa8dc22cc95513.tar.bz2
forums-61e0247f220c9e523e566d517dfa8dc22cc95513.tar.xz
forums-61e0247f220c9e523e566d517dfa8dc22cc95513.zip
Merge pull request #4192 from marc1706/ticket/14496
[ticket/14496] Cache last update of update list instead of using filemtime * marc1706/ticket/14496: [ticket/14496] Destroy update_list_time cache variable on intro [ticket/14496] Cache last update of update list instead of using filemtime
Diffstat (limited to 'phpBB')
-rw-r--r--phpBB/install/install_update.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/phpBB/install/install_update.php b/phpBB/install/install_update.php
index 82ca0fc18d..a00280a925 100644
--- a/phpBB/install/install_update.php
+++ b/phpBB/install/install_update.php
@@ -283,6 +283,7 @@ class install_update extends module
// Make sure the update list is destroyed.
$cache->destroy('_update_list');
+ $cache->destroy('_update_list_time');
$cache->destroy('_diff_files');
$cache->destroy('_expected_files');
break;
@@ -355,7 +356,7 @@ class install_update extends module
// We are directly within an update. To make sure our update list is correct we check its status.
$update_list = ($request->variable('check_again', false, false, \phpbb\request\request_interface::POST)) ? false : $cache->get('_update_list');
- $modified = ($update_list !== false) ? @filemtime($cache->get_driver()->cache_dir . 'data_update_list.' . $phpEx) : 0;
+ $modified = ($update_list !== false) ? $cache->get('_update_list_time') : 0;
// Make sure the list is up-to-date
if ($update_list !== false)
@@ -384,6 +385,7 @@ class install_update extends module
{
$this->get_update_structure($update_list, $expected_files);
$cache->put('_update_list', $update_list);
+ $cache->put('_update_list_time', time());
// Refresh the page if we are still not finished...
if ($update_list['status'] != -1)