aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/posting.php
diff options
context:
space:
mode:
authorNils Adermann <naderman@naderman.de>2013-11-01 07:58:18 -0700
committerNils Adermann <naderman@naderman.de>2013-11-01 07:58:18 -0700
commite118b4f4c0dbca5912f11e0954fa422f36a58353 (patch)
treea4b06c160aa28839fd3bb949be1724ff55aa8ee2 /phpBB/posting.php
parent652365158ab3f788a1a7b31e6e599198d19cc6f7 (diff)
parentae7ef3e09dd284b8876ad74de16321c373d251af (diff)
downloadforums-e118b4f4c0dbca5912f11e0954fa422f36a58353.tar
forums-e118b4f4c0dbca5912f11e0954fa422f36a58353.tar.gz
forums-e118b4f4c0dbca5912f11e0954fa422f36a58353.tar.bz2
forums-e118b4f4c0dbca5912f11e0954fa422f36a58353.tar.xz
forums-e118b4f4c0dbca5912f11e0954fa422f36a58353.zip
Merge pull request #1839 from bantu/task/code-sniffer
More PHP Code Sniffer rules
Diffstat (limited to 'phpBB/posting.php')
-rw-r--r--phpBB/posting.php11
1 files changed, 8 insertions, 3 deletions
diff --git a/phpBB/posting.php b/phpBB/posting.php
index e29b74af65..5db36007c2 100644
--- a/phpBB/posting.php
+++ b/phpBB/posting.php
@@ -381,7 +381,7 @@ if ($mode == 'delete' || $mode == 'soft_delete')
if ($mode == 'bump')
{
if ($bump_time = bump_topic_allowed($forum_id, $post_data['topic_bumped'], $post_data['topic_last_post_time'], $post_data['topic_poster'], $post_data['topic_last_poster_id'])
- && check_link_hash(request_var('hash', ''), "topic_{$post_data['topic_id']}"))
+ && check_link_hash(request_var('hash', ''), "topic_{$post_data['topic_id']}"))
{
$meta_url = phpbb_bump_topic($forum_id, $topic_id, $post_data, $current_time);
meta_refresh(3, $meta_url);
@@ -817,8 +817,13 @@ if ($submit || $preview || $refresh)
// We make sure nobody else made exactly the same change
// we're about to submit by also checking $message_md5 != $post_data['post_checksum']
- if (($edit_post_message_checksum !== '' && $edit_post_message_checksum != $post_data['post_checksum'] && $message_md5 != $post_data['post_checksum'])
- || ($edit_post_subject_checksum !== '' && $edit_post_subject_checksum != $post_data['post_subject_md5'] && md5($post_data['post_subject']) != $post_data['post_subject_md5']))
+ if ($edit_post_message_checksum !== '' &&
+ $edit_post_message_checksum != $post_data['post_checksum'] &&
+ $message_md5 != $post_data['post_checksum']
+ ||
+ $edit_post_subject_checksum !== '' &&
+ $edit_post_subject_checksum != $post_data['post_subject_md5'] &&
+ md5($post_data['post_subject']) != $post_data['post_subject_md5'])
{
if (topic_review($topic_id, $forum_id, 'post_review_edit', $post_id))
{