diff options
author | Marc Alexander <admin@m-a-styles.de> | 2013-11-14 18:16:29 +0100 |
---|---|---|
committer | Marc Alexander <admin@m-a-styles.de> | 2013-11-14 18:16:29 +0100 |
commit | 0d3396487e58091053778c9eb40ebcb6fa86536f (patch) | |
tree | 9d9e5538986c2c48467bad370c38a2b449dd03c9 /phpBB/includes | |
parent | 7f10312bf21dba335a863fb1222db8b9ed64ef0e (diff) | |
download | forums-0d3396487e58091053778c9eb40ebcb6fa86536f.tar forums-0d3396487e58091053778c9eb40ebcb6fa86536f.tar.gz forums-0d3396487e58091053778c9eb40ebcb6fa86536f.tar.bz2 forums-0d3396487e58091053778c9eb40ebcb6fa86536f.tar.xz forums-0d3396487e58091053778c9eb40ebcb6fa86536f.zip |
[ticket/11896] Use $form_time and fix out of bounds $form_time
PHPBB3-11896
Diffstat (limited to 'phpBB/includes')
-rw-r--r-- | phpBB/includes/ucp/ucp_notifications.php | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/phpBB/includes/ucp/ucp_notifications.php b/phpBB/includes/ucp/ucp_notifications.php index de9352a322..63dbe79666 100644 --- a/phpBB/includes/ucp/ucp_notifications.php +++ b/phpBB/includes/ucp/ucp_notifications.php @@ -27,7 +27,8 @@ class ucp_notifications add_form_key('ucp_notification'); $start = $request->variable('start', 0); - $form_time = min($request->variable('form_time', 0), time()); + $form_time = $request->variable('form_time', 0); + $form_time = ($form_time <= 0 || $form_time > time()) ? time() : $form_time; $phpbb_notifications = $phpbb_container->get('notification_manager'); @@ -103,7 +104,7 @@ class ucp_notifications { confirm_box(false, 'NOTIFICATIONS_MARK_ALL_READ', build_hidden_fields(array( 'mark' => 'all', - 'form_time' => time(), + 'form_time' => $form_time, ))); } } |