Skip to content

Commit 6251009

Browse files
author
Mastiuhin Olexandr
committed
MAGETWO-97091: Zip code is not validated for address entered in My Account and for new address entered during checkout
1 parent 50c50d4 commit 6251009

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

app/code/Magento/Customer/Block/DataProviders/PostCodesPatternsAttributeData.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,11 +39,11 @@ public function __construct(PostCodeConfig $postCodeConfig, SerializerInterface
3939
}
4040

4141
/**
42-
* Get post codes in json format
42+
* Get serialized post codes
4343
*
4444
* @return string
4545
*/
46-
public function getPostCodesJson(): string
46+
public function getSerializedPostCodes(): string
4747
{
4848
return $this->serializer->serialize($this->postCodeConfig->getPostCodes());
4949
}

app/code/Magento/Customer/view/frontend/templates/address/edit.phtml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@
188188
{
189189
"#form-validate": {
190190
"addressValidation": {
191-
"postCodes": <?= /* @noEscape */ $block->getPostCodeConfig()->getPostCodesJson(); ?>
191+
"postCodes": <?= /* @noEscape */ $block->getPostCodeConfig()->getSerializedPostCodes(); ?>
192192
}
193193
},
194194
"#country": {

0 commit comments

Comments
 (0)