aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/functions_content.php
diff options
context:
space:
mode:
authorAndreas Fischer <bantu@phpbb.com>2009-08-21 09:44:55 +0000
committerAndreas Fischer <bantu@phpbb.com>2009-08-21 09:44:55 +0000
commit5d2e4e88ab3266b44101714a101d337e0053361e (patch)
tree9c2ed31003d0d3452ab8477b9c376589c0614618 /phpBB/includes/functions_content.php
parent14b11152c601b5bbf1029f237808bfeebd4bf23e (diff)
downloadforums-5d2e4e88ab3266b44101714a101d337e0053361e.tar
forums-5d2e4e88ab3266b44101714a101d337e0053361e.tar.gz
forums-5d2e4e88ab3266b44101714a101d337e0053361e.tar.bz2
forums-5d2e4e88ab3266b44101714a101d337e0053361e.tar.xz
forums-5d2e4e88ab3266b44101714a101d337e0053361e.zip
Allow "0" as censor word and replacement.
Only obtain word censor list if text is not empty. git-svn-id: file:///svn/phpbb/branches/phpBB-3_0_0@10039 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/includes/functions_content.php')
-rw-r--r--phpBB/includes/functions_content.php6
1 files changed, 6 insertions, 0 deletions
diff --git a/phpBB/includes/functions_content.php b/phpBB/includes/functions_content.php
index 7a30f0069e..c265d0ae41 100644
--- a/phpBB/includes/functions_content.php
+++ b/phpBB/includes/functions_content.php
@@ -685,6 +685,12 @@ function censor_text($text)
{
static $censors;
+ // Nothing to do?
+ if ($text === '')
+ {
+ return '';
+ }
+
// We moved the word censor checks in here because we call this function quite often - and then only need to do the check once
if (!isset($censors) || !is_array($censors))
{