Whitespaces break length ghecks, damnit.
This commit is contained in:
parent
0d6d5ac11a
commit
2d820491e6
2
Block.pm
2
Block.pm
@ -291,6 +291,8 @@ sub validate_htmlarea {
|
||||
my $scrubber = HTML::Scrubber -> new();
|
||||
my $nohtml = $scrubber -> scrub($text);
|
||||
|
||||
$nohtml =~ s/[\t\r\n]//g; # Kill some kinds of whitespace that may be left by scrubber that will confuse length checks.
|
||||
|
||||
# If the text area is empty, deal with the whole default/required malarky
|
||||
if(!defined($nohtml) || !$nohtml) {
|
||||
# If the parameter is required, return empty and an error
|
||||
|
Loading…
x
Reference in New Issue
Block a user