diff --git a/vendor/magento/module-reward/Model/System/Config/Backend/Balance.php b/vendor/magento/module-reward/Model/System/Config/Backend/Balance.php index c3b26591b1bb..87a6431a4a2e 100644 --- a/vendor/magento/module-reward/Model/System/Config/Backend/Balance.php +++ b/vendor/magento/module-reward/Model/System/Config/Backend/Balance.php @@ -28,12 +28,12 @@ public function beforeSave() return $this; } - if ($this->getFieldsetDataValue('min_points_balance') < 0) { + if ((int)$this->getFieldsetDataValue('min_points_balance') < 0) { $message = __('The "Minimum Reward Points Balance" is invalid. ' . 'The balance needs to be a positive number or left empty. Verify and try again.'); throw new LocalizedException($message); } - if ($this->getFieldsetDataValue('max_points_balance') < 0) { + if ((int)$this->getFieldsetDataValue('max_points_balance') < 0) { $message = __('The "Cap Reward Points Balance" is invalid. ' . 'The balance needs to be a positive number or left empty. Verify and try again.'); throw new LocalizedException($message);