respect-validation/library/Rules
Henrique Moody 779c0c1503
Do not accept whitespace by default in "Alnum" rule
The "Alnum" rule is supposed to validate alphanumeric values, but
instead, it also validates any whitespace character as valid.

The rule also accepts a list of characters on its constructor, so it the
users intentionally want some specific characters to also be allowed it
is better than they also defined these characters on the rule's
constructor.

While refactoring the rule I could notice that "AbstractCtypeRule" is
just an overhead that does not add much to it, so instead of extending
it "Alnum" now extends "AbstractFilterRule" directly (which is the
parent of "AbstractCtypeRule").

And since we want all rules to follow our contribution guidelines, this
commit also make sure the "Alnum" rule is in accordance with that.

Signed-off-by: Henrique Moody <henriquemoody@gmail.com>
2018-09-04 00:05:24 +02:00
..
Locale Merge branch '1.1' 2018-05-19 16:46:58 +02:00
AbstractAge.php Refactor rules related to age 2018-02-24 09:28:54 +01:00
AbstractComparison.php Fix issues after merging 1.1 2018-08-01 20:46:34 +02:00
AbstractComposite.php Rename "Related" to "Child" 2018-08-02 11:18:33 +02:00
AbstractCtypeRule.php Changes on PHP-CS-Fixer configuration 2018-01-04 17:59:37 +01:00
AbstractEnvelope.php Add return type to "reportError()" 2018-06-01 10:34:21 +02:00
AbstractFilterRule.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
AbstractLocaleWrapper.php Fix coding standards 2018-02-04 01:00:30 +01:00
AbstractRegexRule.php Changes on PHP-CS-Fixer configuration 2018-01-04 17:59:37 +01:00
AbstractRelated.php Rename "Related" to "Child" 2018-08-02 11:18:33 +02:00
AbstractRule.php Add type hinting and return type to "setTemplate" 2018-06-01 10:46:51 +02:00
AbstractSearcher.php Apply contribution guidelines to "AbstractSearcher" 2018-01-19 21:41:34 +01:00
AbstractWrapper.php Ensure names are always string 2018-05-27 16:12:05 +02:00
AllOf.php Rename "Related" to "Child" 2018-08-02 11:18:33 +02:00
Alnum.php Do not accept whitespace by default in "Alnum" rule 2018-09-04 00:05:24 +02:00
Alpha.php Changes on PHP-CS-Fixer configuration 2018-01-04 17:59:37 +01:00
AlwaysInvalid.php Apply contribution guidelines to "AlwaysInvalid" rule 2018-06-04 09:12:14 +02:00
AlwaysValid.php Apply contribution guidelines to "AlwaysValid" rule 2018-06-04 09:12:11 +02:00
AnyOf.php Rename "Related" to "Child" 2018-08-02 11:18:33 +02:00
ArrayType.php Apply contribution guidelines to "ArrayType" rule 2018-03-16 11:19:14 +01:00
ArrayVal.php Apply contribution guidelines to "ArrayVal" rule 2018-04-02 23:19:22 +02:00
Attribute.php Apply contribution guidelines to "Attribute" rule 2018-05-31 13:50:36 +02:00
Base.php Apply contribution guidelines to "Base" rule 2018-06-09 08:54:34 +02:00
Base64.php Apply contribution guidelines to "Base64" rule 2018-06-09 08:54:39 +02:00
Between.php Make "Min" always inclusive 2018-05-31 17:14:23 +02:00
BoolType.php Apply contribution guidelines to "BoolType" rule 2018-03-27 00:09:58 +02:00
BoolVal.php Apply contribution guidelines to "BoolVal" rule 2018-06-09 08:54:42 +02:00
Bsn.php Apply contribution guidelines to "Bsn" rule 2018-06-10 13:01:10 -03:00
Call.php Intercept throwables in the "Call" rule 2018-08-22 17:04:20 +02:00
CallableType.php Apply contribution guidelines to "CallableType" rule 2018-05-19 17:07:59 +02:00
Callback.php Apply contribution guidelines to "Callback" rule 2018-06-11 18:47:28 +02:00
Charset.php Apply contribution guidelines to "Charset" rule 2018-06-11 22:24:28 +02:00
Cnh.php Apply contribution guidelines to "Cnh" rule 2018-06-11 22:24:28 +02:00
Cnpj.php Apply contribution guidelines to "Cnpj" rule 2018-06-15 17:24:19 +02:00
Cntrl.php Changes on PHP-CS-Fixer configuration 2018-01-04 17:59:37 +01:00
Consonant.php Changes on PHP-CS-Fixer configuration 2018-01-04 17:59:37 +01:00
Contains.php Apply contribution guidelines to "Contains" rule 2018-06-04 09:11:58 +02:00
Countable.php Apply contribution guidelines to "Countable" rule 2018-06-04 09:12:04 +02:00
CountryCode.php Apply contribution guidelines to "CountryCode" rule 2018-06-15 18:49:52 +02:00
Cpf.php Apply contribution guidelines to "Cpf" rule 2018-06-04 09:12:07 +02:00
CreditCard.php Apply contribution guidelines to "CreditCard" rule 2018-06-15 22:12:17 +02:00
CurrencyCode.php Apply contribution guidelines to "CurrencyCode" rule 2018-06-18 20:55:43 +02:00
Date.php Do not overwrite method configure() 2018-05-27 16:12:05 +02:00
DateTime.php Do not overwrite method configure() 2018-05-27 16:12:05 +02:00
Digit.php Changes on PHP-CS-Fixer configuration 2018-01-04 17:59:37 +01:00
Directory.php Apply contribution guidelines to "Directory" rule 2018-06-20 22:34:21 +02:00
Domain.php Setup PHPStan (PHP Static Analysis Tool) 2018-08-22 19:10:20 +02:00
Each.php Rename "Related" to "Child" 2018-08-02 11:18:33 +02:00
Email.php Remove support "egulias/email-validator" ~1.0 2018-08-22 17:22:46 +02:00
EndsWith.php Apply contribution guidelines to "EndsWith" rule 2018-07-01 14:11:56 +02:00
Equals.php Apply contribution guidelines to "Equals" rule 2018-01-15 09:16:45 +01:00
Equivalent.php Create "Equivalent" rule 2018-06-23 17:38:53 +02:00
Even.php Apply contribution guidelines to "Even" rule 2018-05-31 08:37:38 +02:00
Executable.php Apply contribution guidelines to "Executable" rule 2018-06-20 22:34:21 +02:00
Exists.php Apply contribution guidelines to "Exists" rule 2018-06-20 22:34:21 +02:00
Extension.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
Factor.php Remove method stringify from ValidationException 2018-05-27 16:12:05 +02:00
FalseVal.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
Fibonacci.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
File.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
FilterVar.php Apply contribution guidelines to "FilterVar" rule 2018-06-11 18:40:05 +02:00
Finite.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
FloatType.php Apply contribution guidelines to "FloatType" rule 2018-03-27 00:17:34 +02:00
FloatVal.php Apply contribution guidelines to "FloatVal" rule 2018-06-05 09:24:07 +02:00
Graph.php Changes on PHP-CS-Fixer configuration 2018-01-04 17:59:37 +01:00
GreaterThan.php Fix issues after merging 1.1 2018-08-01 20:46:34 +02:00
HexRgbColor.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
Identical.php Apply contribution guidelines to "Identical" rule 2018-01-15 09:35:22 +01:00
IdentityCard.php Refactor "AbstractWrapper" class 2018-01-28 13:20:27 +01:00
Image.php Apply contribution guidelines to "Image" rule 2018-07-23 21:55:54 +02:00
Imei.php Apply contribution guidelines to "Imei" rule 2018-08-16 21:54:16 +02:00
In.php Apply contribution guidelines to "In" rule 2018-08-19 16:01:10 -03:00
Infinite.php Apply contribution guidelines to "Infinite" rule 2018-08-16 21:54:16 +02:00
Instance.php Apply contribution guidelines to "Instance" rule 2018-08-16 21:54:17 +02:00
IntType.php Apply contribution guidelines to "IntType" rule 2018-03-27 00:25:26 +02:00
IntVal.php Merge branch '1.1' 2018-08-01 22:08:30 +02:00
Ip.php Do not overwrite method configure() 2018-05-27 16:12:05 +02:00
IterableType.php Apply contribution guidelines to "IterableType" rule 2018-06-01 14:23:41 +02:00
Json.php Apply contribution guidelines to "Json" rule 2018-08-30 23:08:27 -03:00
Key.php Apply contribution guidelines to "Attribute" rule 2018-05-31 13:50:36 +02:00
KeyNested.php Apply contribution guidelines to "Attribute" rule 2018-05-31 13:50:36 +02:00
KeySet.php Refactor "KeySet" rule 2018-03-03 18:59:36 +01:00
KeyValue.php Refactor ValidationException 2018-05-27 16:12:05 +02:00
LanguageCode.php Declare visibility for constants 2018-05-27 16:12:05 +02:00
LeapDate.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
LeapYear.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
Length.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
LessThan.php Fix issues after merging 1.1 2018-08-01 20:46:34 +02:00
Lowercase.php Apply contribution guidelines to "Lowercase" rule 2018-06-05 09:22:18 +02:00
Luhn.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
MacAddress.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
Max.php Fix issues after merging 1.1 2018-08-01 20:46:34 +02:00
MaxAge.php Rename "MaximumAge" and "MinimumAge" rules 2018-05-31 17:01:15 +02:00
Mimetype.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
Min.php Fix issues after merging 1.1 2018-08-01 20:46:34 +02:00
MinAge.php Rename "MaximumAge" and "MinimumAge" rules 2018-05-31 17:01:15 +02:00
Multiple.php Apply contribution guidelines to "Multiple" rule 2018-07-16 08:15:57 +02:00
Negative.php Apply contribution guidelines to "Negative" rule 2018-06-06 08:00:58 +02:00
NfeAccessKey.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
Nif.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
No.php Changes on PHP-CS-Fixer configuration 2018-01-04 17:59:37 +01:00
NoneOf.php Rename "Related" to "Child" 2018-08-02 11:18:33 +02:00
Not.php Refactor ValidationException 2018-05-27 16:12:05 +02:00
NotBlank.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
NotEmpty.php Apply contribution guidelines to "NotEmpty" rule 2018-05-02 16:04:05 +02:00
NotOptional.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
NoWhitespace.php Apply contribution guidelines to "NoWhitespace" rule 2018-06-09 08:54:25 +02:00
Nullable.php Create "Nullable" rule 2018-02-23 09:20:51 +01:00
NullType.php Apply contribution guidelines to "NullType" rule 2018-03-27 00:32:05 +02:00
Number.php Apply contribution guidelines to "Number" rule 2018-08-16 21:54:17 +02:00
NumericVal.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
ObjectType.php Apply contribution guidelines to "ObjectType" rule 2018-05-19 19:12:59 +02:00
Odd.php Apply contribution guidelines to "Odd" rule 2018-06-06 08:00:58 +02:00
OneOf.php Rename "Related" to "Child" 2018-08-02 11:18:33 +02:00
Optional.php Fix coding standards 2018-02-04 01:00:30 +01:00
PerfectSquare.php Apply contribution guidelines to "PerfectSquare" rule 2018-06-23 21:43:02 +02:00
Pesel.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
Phone.php Changes on PHP-CS-Fixer configuration 2018-01-04 17:59:37 +01:00
PhpLabel.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
Pis.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
Positive.php Apply contribution guidelines to "Positive" rule 2018-06-05 22:26:58 +02:00
PostalCode.php Merge branch '1.1' 2018-08-01 20:22:37 +02:00
PrimeNumber.php Apply contribution guidelines to "PrimeNumber" rule 2018-06-09 08:54:30 +02:00
Printable.php Rename 'Prnt' rule to 'Printable' 2018-05-31 16:00:43 +02:00
Punct.php Changes on PHP-CS-Fixer configuration 2018-01-04 17:59:37 +01:00
Readable.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
Regex.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
ResourceType.php Apply contribution guidelines to "ResourceType" rule 2018-03-27 00:44:48 +02:00
Roman.php Changes on PHP-CS-Fixer configuration 2018-01-04 17:59:37 +01:00
ScalarVal.php Apply contribution guidelines to "ScalarVal" rule 2018-03-09 15:07:58 +01:00
Sf.php Change how "Sf" rule works 2018-08-22 17:46:21 +02:00
Size.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
Slug.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
Sorted.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
Space.php Changes on PHP-CS-Fixer configuration 2018-01-04 17:59:37 +01:00
StartsWith.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
StringType.php Apply contribution guidelines to "StringType" rule 2018-03-09 15:56:10 +01:00
StringVal.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
SubdivisionCode.php Refactor "AbstractWrapper" class 2018-01-28 13:20:27 +01:00
Subset.php Create "Subset" rule 2018-07-01 15:08:07 +02:00
SymbolicLink.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
Time.php Do not overwrite method configure() 2018-05-27 16:12:05 +02:00
Tld.php Merge branch '1.1' 2018-08-22 19:09:55 +02:00
TrueVal.php Apply contribution guidelines to "TrueVal" rule 2018-06-15 22:12:17 +02:00
Type.php Apply contribution guidelines to "Type" rule 2018-06-15 22:12:17 +02:00
Unique.php Apply contribution guidelines to "Unique" rule 2018-06-18 23:15:19 +02:00
Uploaded.php Apply contribution guidelines to "Uploaded" rule 2018-06-20 22:34:21 +02:00
Uppercase.php Apply contribution guidelines to "Uppercase" rule 2018-06-02 16:03:11 +02:00
Url.php Apply contribution guidelines to "Url" rule 2018-06-11 18:22:09 +02:00
Uuid.php Changes on PHP-CS-Fixer configuration 2018-01-04 17:59:37 +01:00
Vatin.php Refactor "AbstractWrapper" class 2018-01-28 13:20:27 +01:00
Version.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
VideoUrl.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
Vowel.php Changes on PHP-CS-Fixer configuration 2018-01-04 17:59:37 +01:00
When.php Method assert() should not have a return value 2018-01-28 17:38:40 +01:00
Writable.php Method validate() should always return a boolean 2018-01-28 17:38:36 +01:00
Xdigit.php Changes on PHP-CS-Fixer configuration 2018-01-04 17:59:37 +01:00
Yes.php Changes on PHP-CS-Fixer configuration 2018-01-04 17:59:37 +01:00
Zend.php Rename "Related" to "Child" 2018-08-02 11:18:33 +02:00