mirror of
https://github.com/Respect/Validation.git
synced 2024-06-09 01:02:16 +02:00
Fix Irish postal code validation
Co-authored-by: Henrique Moody <henriquemoody@gmail.com>
This commit is contained in:
parent
f246939221
commit
9bafee191d
|
@ -81,7 +81,7 @@ class PostalCode extends Regex
|
|||
'HT' => '/^(?:HT)*(\d{4})$/',
|
||||
'HU' => '/^(\d{4})$/',
|
||||
'ID' => '/^(\d{5})$/',
|
||||
'IE' => '/^[A-Z]\d{2}$|^[A-Z]{3}[A-Z]{4}$/',
|
||||
'IE' => '/^([AC-FHKNPRTV-Y][0-9]{2}|D6W) ?[0-9AC-FHKNPRTV-Y]{4}$/',
|
||||
'IL' => '/^(\d{5})$/',
|
||||
'IM' => '/^((?:(?:[A-PR-UWYZ][A-HK-Y]\d[ABEHMNPRV-Y0-9]|[A-PR-UWYZ]\d[A-HJKPS-UW0-9])\s\d[ABD-HJLNP-UW-Z]{2})|GIR\s?0AA)$/',
|
||||
'IN' => '/^(\d{6})$/',
|
||||
|
|
|
@ -100,6 +100,8 @@ class PostalCodeTest extends TestCase
|
|||
['PT', '3660606'],
|
||||
['CO', '110231'],
|
||||
['KR', '03187'],
|
||||
['IE', 'D14 YD91'],
|
||||
['IE', 'D6W 3333'],
|
||||
];
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue