File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed
app/code/Magento/Eav/Model/Validator/Attribute Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change 3
3
* Copyright © Magento, Inc. All rights reserved.
4
4
* See COPYING.txt for license details.
5
5
*/
6
+ declare (strict_types=1 );
6
7
7
8
namespace Magento \Eav \Model \Validator \Attribute ;
8
9
9
10
use Magento \Eav \Model \Entity \Attribute ;
10
11
use Magento \Framework \Exception \LocalizedException ;
12
+ use Magento \Framework \Validator \AbstractValidator ;
13
+ use Zend_Validate ;
11
14
12
15
/**
13
16
* Class Code
14
17
*
15
18
* Validation EAV attribute code
16
19
*/
17
- class Code extends \ Magento \ Framework \ Validator \ AbstractValidator
20
+ class Code extends AbstractValidator
18
21
{
19
22
/**
20
23
* Validates the correctness of the attribute code
@@ -45,7 +48,7 @@ public function isValid($attributeCode)
45
48
*/
46
49
$ minLength = Attribute::ATTRIBUTE_CODE_MIN_LENGTH ;
47
50
$ maxLength = Attribute::ATTRIBUTE_CODE_MAX_LENGTH ;
48
- $ isAllowedLength = \ Zend_Validate::is (
51
+ $ isAllowedLength = Zend_Validate::is (
49
52
trim ($ attributeCode ),
50
53
'StringLength ' ,
51
54
['min ' => $ minLength , 'max ' => $ maxLength ]
You can’t perform that action at this time.
0 commit comments