Skip to content

Commit 2ef8843

Browse files
committed
MC-32651: A Gift Card with minimum value of an open amount, greater than maximum value, can be created
1 parent 82c4a62 commit 2ef8843

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

app/code/Magento/PageBuilder/view/adminhtml/web/js/form/element/validator-rules-mixin.js

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -107,14 +107,15 @@ define([
107107
validator.addRule(
108108
ruleName,
109109
function (value, params) {
110-
var allNumbers = true;
110+
var allNumbers = true,
111+
handler = rule.handler.bind(this);
111112

112113
if (typeof value !== 'object') {
113-
return rule.handler(value, params);
114+
return handler(value, params);
114115
}
115116

116117
_.flatten(_.map(value, _.values)).forEach(function (val) {
117-
if (!rule.handler(val, params)) {
118+
if (!handler(val, params)) {
118119
allNumbers = false;
119120

120121
return allNumbers;

0 commit comments

Comments
 (0)