Renato Moura
e4ae02fe94
Fix "Cnpj" rule
2017-01-25 17:41:21 +01:00
Pedro Manjarrez
527b1882dd
Update README.md
...
Fixed typo on Exception types section.
2016-12-29 11:34:12 -06:00
Henrique Moody
710e807a68
Merge branch '1.0' into 1.1
2016-10-29 15:29:17 +02:00
Henrique Moody
f82fcf0762
Prevent "Regex" to process non-string inputs
2016-10-29 15:21:14 +02:00
Henrique Moody
bd636cc75e
Add support for "egulias/email-validator" 2.x
2016-10-29 15:20:13 +02:00
Henrique Moody
e457f19dbd
Merge branch '1.0' into 1.1
2016-09-20 08:44:39 +02:00
Henrique Moody
98050476c6
Always return a valid exception
...
If calling the method `getExceptionForPath()` when the exception was
nested but had no child it was returning null. This commit ensures that
it always return a valid exception.
2016-09-19 18:22:39 +02:00
Henrique Moody
3fa5bc0489
Merge branch '1.0' into 1.1
2016-09-19 11:24:33 +02:00
Emmerson
d0a98ae5d3
Date rule accepting scalar and DateTimeInterface
2016-09-19 10:13:01 +02:00
Henrique Moody
c79d8fdf4f
Change file mode of "Image" rule
2016-09-19 09:32:42 +02:00
Gabriel Pedro
a772d7f89a
Replace CNH validation algorithm
...
The old algorithm not working with some CNH values, e.g 00641829409.
You can even do some checking on
http://www.detran.pr.gov.br/modules/catasg/servicos-detalhes.php?tema=motorista&id=239 .
Original algo can be found on
http://forum.imasters.com.br/topic/400293-validate-br .
2016-09-18 13:25:18 +02:00
Henrique Moody
d30b3d1b49
Merge branch '1.0' into 1.1
2016-09-17 22:59:31 +02:00
Henrique Moody
8b32270d28
Add "symfony/polyfill-mbstring" as a dependency
2016-09-17 22:30:35 +02:00
Henrique Moody
edf4e49ac6
Merge branch '1.0' into 1.1
2016-09-17 21:30:00 +02:00
Henrique Moody
4bcc4027f8
Try to use the getRelatedByName()
method first
...
Then using the `findMessages()` method, tries to use the method
`getRelatedByName()` before using the `findRelated()` method.
This change was made because since on `KeyNested` rule you may have
names with '.' we'll never get the proper exception using
`findRelated()`.
2016-09-17 21:11:55 +02:00
Henrique Moody
98443bad0c
Get the proper exception when using findMessage()
2016-09-17 21:04:24 +02:00
Henrique Moody
494b67871f
Fix wrong behaviour on AbstractRelated
...
When you define the name for an `AbstractRelated` instance, you expect
that it also define the name for its child. But, when the child already
had a name the `AbstractRelated` was overwriting its name with the
`reference`.
2016-09-17 20:23:38 +02:00
Henrique Moody
6d0e3a2422
Merge branch '1.0' into 1.1
2016-09-13 11:32:43 +02:00
Henrique Moody
7e88a7a0c8
Always check the type then executing KeyNested
2016-09-12 18:06:10 +02:00
Henrique Moody
53b737513b
Merge branch '1.0' into 1.1
2016-08-03 11:06:53 +02:00
Henrique Moody
fb7f19f9ad
Fix missing docblock for "iterableType" rule
2016-08-03 11:05:28 +02:00
Henrique Moody
cc179f9209
Merge branch '1.0' into 1.1
2016-08-03 10:53:00 +02:00
Henrique Moody
c044b8bb09
Cast integer to use with long2ip function
2016-08-03 10:43:33 +02:00
Henrique Moody
e5fdd87a16
Rename "Iterable" to "IterableType"
2016-08-03 10:43:33 +02:00
Henrique Moody
8c49c6a75b
Run PHP 7.1 on Travis
2016-08-03 09:41:33 +02:00
Tomasz Regdos
73a9ff40eb
Fix Pesel validator when first char is zero
2016-07-01 16:22:12 +02:00
Henrique Moody
b8ecd59f48
Merge branch '1.0' into 1.1
2016-05-07 20:54:08 +02:00
Marcel Prince
6597aa5114
Add method Identical To Validator.php
2016-05-07 20:51:56 +02:00
Henrique Moody
2d3c0ceed8
Merge branch '1.0' into 1.1
2016-05-05 13:14:59 +02:00
Henrique Moody
62316fc8b9
Merge branch '0.9' into 1.0
2016-05-05 13:14:24 +02:00
Mohammad Amiri
1ce8ac8c7e
Update FilterVar.md
...
Fixed a mistake in Url validation examples
2016-05-05 13:12:45 +02:00
Henrique Moody
3e1988f9c1
Merge branch '1.0' into 1.1
2016-05-05 13:03:25 +02:00
Emmerson
d9a4c78b16
Fixes 'KeySet' rule when input is not array type
2016-05-05 13:01:04 +02:00
Henrique Moody
af0be2fbcd
Update "CHANGELOG.md" file
2016-04-23 22:11:23 -03:00
Kennedy Tedesco
cca733919c
Throw an exception when age is not an integer
2016-04-23 21:43:19 -03:00
Augusto Pascutti
9460a4c237
Ensure namespace separator on appended prefixes
...
Appending a prefix to search new rules under required that the namespace
(prefix) being added always ended with a trailing namespace character so
rules could successfully be found under it. This ensures that the
separator is always present.
Changes a test for a rule which does not implement Respect's interface
to an actual class so we don't need to declare one to use as a stub.
2016-04-23 21:20:54 -03:00
Henrique Moody
bb0e40a08e
Set template for the only rule in the chain
...
When there is just one rule in the chain and the there is a defined
template for that, the expected behaviour when using the `check()`
method is to see the exception message with the defined template.
2016-04-08 13:39:57 -03:00
Henrique Moody
46541c7e46
Allow the define brands for credit card validation
2016-04-06 16:42:49 -03:00
Ruben Vermeersch
7a907e6795
Fix missing change from arr() to arrayVal()
2016-04-06 10:08:40 +02:00
Henrique Moody
f3ad53dd14
Merge branch '1.0'
2016-03-31 14:44:58 -03:00
Henrique Moody
294368294f
Merge branch '0.9' into 1.0
2016-03-31 14:39:15 -03:00
Henrique Moody
7d978d64e3
Merge branch '0.8' into 0.9
2016-03-31 14:26:10 -03:00
Henrique Moody
eecc696792
Fix wrong date parsing on Date rule
...
The `DateTime::createFromFormat()` tries to guess the date too much and
sometimes wrong parsing may happen:
```php
echo DateTime::createFromFormat('Ym', '202309')->format('Ym');
```
The output of the above code is "202310", not "202309".
Using `date_parse_from_format()` we get a more precise parsing.
2016-03-31 14:18:22 -03:00
Emmerson
f40eb63d7b
Create "PhpLabel" rule
2016-03-04 21:48:25 -03:00
Henrique Moody
b1d0acc2e5
Fix some coding standards with php-cs-fixer
2016-03-04 21:42:27 -03:00
Henrique Moody
78449ce9b0
Merge branch '1.0'
2016-02-26 12:22:33 -03:00
Henrique Moody
4b2f159206
Merge branch '0.9' into 1.0
2016-02-26 12:21:26 -03:00
Henrique Moody
7febcf3dd6
Merge branch '0.8' into 0.9
2016-02-26 12:20:26 -03:00
Alasdair North
3bf4957caf
AbstractWrapper should pass on setName calls to the wrapped Validatable.
2016-02-26 12:18:05 -03:00
Samuel Heinzmann
ce3f885862
Create "Fibonacci" rule
2016-02-13 14:02:21 -02:00