Skip to content

Commit

Permalink
Allowing usage of the capital letters in attribute code
Browse files Browse the repository at this point in the history
  • Loading branch information
eduard13 committed Feb 4, 2019
1 parent 82f5511 commit 4488371
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/code/Magento/Eav/Model/Validator/Attribute/Code.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ public function isValid($attributeCode): bool
* Check attribute_code for allowed characters
*/
if (trim($attributeCode)
&& !preg_match('/^[a-z][a-z0-9_]*$/', trim($attributeCode))
&& !preg_match('/^[a-zA-Z]+[a-zA-Z0-9_]*$/', trim($attributeCode))
) {
throw new LocalizedException(
__(
Expand Down

0 comments on commit 4488371

Please sign in to comment.