Skip to content

Commit abc096d

Browse files
committed
work
1 parent 733c6c1 commit abc096d

File tree

3 files changed

+1
-12
lines changed

3 files changed

+1
-12
lines changed

app/code/core/Mage/Admin/Model/Variable.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
* @license https://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
1111
*/
1212

13-
1413
/**
1514
* @method Mage_Admin_Model_Resource_Variable _getResource()
1615
* @method Mage_Admin_Model_Resource_Variable getResource()

app/code/core/Mage/Adminhtml/Model/Email/PathValidator.php

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -26,16 +26,6 @@ public function isValid(mixed $value): bool
2626
return true;
2727
}
2828

29-
public function getMessages(): array
30-
{
31-
return [Mage::helper('adminhtml')->__('The configuration path is not valid for email templates.')];
32-
}
33-
34-
public function getMessage(): string
35-
{
36-
return Mage::helper('adminhtml')->__('The configuration path is not valid for email templates.');
37-
}
38-
3929
public function isEncryptedNodePath(string $path): bool
4030
{
4131
$configModel = Mage::getSingleton('adminhtml/config');

app/code/core/Mage/Adminhtml/controllers/Catalog/Product/AttributeController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -198,7 +198,7 @@ public function saveAction()
198198

199199
//validate attribute_code
200200
if (isset($data['attribute_code'])) {
201-
if (!preg_match('/^(?!event$)[a-z][a-z_0-9]{1,254}$/', $data['attribute_code'])) {
201+
if (!Mage::helper('core')->isValidRegex($data['attribute_code'], '/^(?!event$)[a-z][a-z_0-9]{1,254}$/')) {
202202
$session->addError(
203203
Mage::helper('catalog')->__('Attribute code is invalid. Please use only letters (a-z), numbers (0-9) or underscore(_) in this field, first character should be a letter. Do not use "event" for an attribute code.'),
204204
);

0 commit comments

Comments
 (0)