From 3f5b4741f13d21bff5b5ff6489a6b0da7f9978a9 Mon Sep 17 00:00:00 2001 From: jisse Reitsma Date: Tue, 13 Dec 2022 08:33:13 +0100 Subject: [PATCH] Backend model prevents saving container ID --- Model/Config/Backend/ContainerId.php | 4 ++-- composer.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Model/Config/Backend/ContainerId.php b/Model/Config/Backend/ContainerId.php index 58b9f861..d98c65c8 100644 --- a/Model/Config/Backend/ContainerId.php +++ b/Model/Config/Backend/ContainerId.php @@ -10,8 +10,8 @@ class ContainerId extends Value { public function beforeSave() { - if ($this->validate()) { - throw new InvalidConfig('Invalid container ID. It should start with "GTM-"'); + if (false === $this->validate()) { + throw new InvalidConfig('Invalid container ID "' . $this->getValue() . '". It should start with "GTM-"'); } return parent::beforeSave(); diff --git a/composer.json b/composer.json index 7512accc..c50b516c 100644 --- a/composer.json +++ b/composer.json @@ -1,6 +1,6 @@ { "name": "yireo/magento2-googletagmanager2", - "version": "3.0.0", + "version": "3.0.1", "license": "OSL-3.0", "type": "magento2-module", "homepage": "https://www.yireo.com/software/magento-extensions/googletagmanager2",