aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/posting.php
diff options
context:
space:
mode:
authorMeik Sievertsen <acydburn@phpbb.com>2008-01-05 16:10:10 +0000
committerMeik Sievertsen <acydburn@phpbb.com>2008-01-05 16:10:10 +0000
commitf0dea060972a48460ce64d3cdf885d82383763c6 (patch)
tree8ae56525469a3c62b35d14f38375554acbf7f1e3 /phpBB/posting.php
parenta4633d8ac09f50aceb9e5568baff59de61508bc8 (diff)
downloadforums-f0dea060972a48460ce64d3cdf885d82383763c6.tar
forums-f0dea060972a48460ce64d3cdf885d82383763c6.tar.gz
forums-f0dea060972a48460ce64d3cdf885d82383763c6.tar.bz2
forums-f0dea060972a48460ce64d3cdf885d82383763c6.tar.xz
forums-f0dea060972a48460ce64d3cdf885d82383763c6.zip
Correctly check empty subjects/messages (Bug #17915)
Do not check usernames against word censor list. Disallowed usernames is already checked and word censor belong to posts. (Bug #17745) Additionally include non-postable forums for moderators forums shown within the teams list. (Bug #17265) git-svn-id: file:///svn/phpbb/trunk@8306 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/posting.php')
-rw-r--r--phpBB/posting.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/phpBB/posting.php b/phpBB/posting.php
index 1236361e18..9ddaf52acd 100644
--- a/phpBB/posting.php
+++ b/phpBB/posting.php
@@ -520,12 +520,12 @@ if ($save && $user->data['is_registered'] && $auth->acl_get('u_savedrafts') && (
}
else
{
- if (!$subject || !utf8_clean_string($subject))
+ if (utf8_clean_string($subject) === '')
{
$error[] = $user->lang['EMPTY_SUBJECT'];
}
- if (!$message)
+ if (utf8_clean_string($message) === '')
{
$error[] = $user->lang['TOO_FEW_CHARS'];
}
@@ -769,7 +769,7 @@ if ($submit || $preview || $refresh)
}
// Parse subject
- if (!$preview && !$refresh && !utf8_clean_string($post_data['post_subject']) && ($mode == 'post' || ($mode == 'edit' && $post_data['topic_first_post_id'] == $post_id)))
+ if (!$preview && !$refresh && utf8_clean_string($post_data['post_subject']) === '' && ($mode == 'post' || ($mode == 'edit' && $post_data['topic_first_post_id'] == $post_id)))
{
$error[] = $user->lang['EMPTY_SUBJECT'];
}