From 2c0bd6359754d63d10caad0b49566b7e2ebaa259 Mon Sep 17 00:00:00 2001 From: Gabor Peter Suranyi Date: Thu, 16 Jul 2015 10:42:14 +0100 Subject: [PATCH] Loosened Regex on GB postcodes The space is casually ignored by customers. It doesn't really matter, and won't cause any delivery / billing issues. Other option is formatting the postcode input to contain the space. (The second part after the potential whitespace is always [0-9]{1}[a-zA-Z]{2}) --- app/code/Magento/Directory/etc/zip_codes.xml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/app/code/Magento/Directory/etc/zip_codes.xml b/app/code/Magento/Directory/etc/zip_codes.xml index dfca9b740fa03..1c9a840a69633 100644 --- a/app/code/Magento/Directory/etc/zip_codes.xml +++ b/app/code/Magento/Directory/etc/zip_codes.xml @@ -455,12 +455,12 @@ - ^[a-zA-Z]{2}[0-9]{2}\s[0-9]{1}[a-zA-Z]{2}$ - ^[a-zA-Z]{1}[0-9]{1}[a-zA-Z]{1}\s[0-9]{1}[a-zA-Z]{2}$ - ^[a-zA-Z]{2}[0-9]{1}\s[0-9]{1}[a-zA-Z]{2}$ - ^[a-zA-Z]{2}[0-9]{1}[a-zA-Z]{1}\s[0-9]{1}[a-zA-Z]{2}$ - ^[a-zA-Z]{1}[0-9]{2}\s[0-9]{1}[a-zA-Z]{2}$ - ^[a-zA-Z]{1}[0-9]{1}\s[0-9]{1}[a-zA-Z]{2}$ + ^[a-zA-Z]{2}[0-9]{2}\s?[0-9]{1}[a-zA-Z]{2}$ + ^[a-zA-Z]{1}[0-9]{1}[a-zA-Z]{1}\s?[0-9]{1}[a-zA-Z]{2}$ + ^[a-zA-Z]{2}[0-9]{1}\s?[0-9]{1}[a-zA-Z]{2}$ + ^[a-zA-Z]{2}[0-9]{1}[a-zA-Z]{1}\s?[0-9]{1}[a-zA-Z]{2}$ + ^[a-zA-Z]{1}[0-9]{2}\s?[0-9]{1}[a-zA-Z]{2}$ + ^[a-zA-Z]{1}[0-9]{1}\s?[0-9]{1}[a-zA-Z]{2}$