WTF was I thinking with this validator check?
This commit is contained in:
parent
1e2d7a5267
commit
5d56f4e7ff
4
Block.pm
4
Block.pm
@ -201,8 +201,8 @@ sub validate_string {
|
||||
|
||||
# Is the string too short (we only need to check if it's required or has content) ? If so, store it and return an error.
|
||||
return ($text, $self -> {"template"} -> replace_langvar("BLOCK_VALIDATE_TOOSHORT", "", {"***field***" => $settings -> {"nicename"},
|
||||
"***minlen***" => $settings -> {"minlen"}}))
|
||||
if(($settings -> {"required"} || length($text)) && $settings -> {"minlen"} && length($text) < $settings -> {"minlen"});
|
||||
"***minlen***" => $settings -> {"minlen"}}))
|
||||
if($settings -> {"minlen"} && length($text) < $settings -> {"minlen"});
|
||||
|
||||
# Get here and all the tests have been passed or skipped
|
||||
return ($text, undef);
|
||||
|
Loading…
x
Reference in New Issue
Block a user