Add strict checks for value of secret

This commit is contained in:
Khushboo Verma 2025-02-08 16:28:04 +05:30
parent ac8a29f047
commit 7ce0e3c38c

View file

@ -76,7 +76,7 @@ class Update extends Base
throw new Exception(Exception::VARIABLE_NOT_FOUND);
}
if ($variable->getAttribute('secret') && !$secret) {
if ($variable->getAttribute('secret') === true && $secret === false) {
throw new Exception(Exception::VARIABLE_CANNOT_UNSET_SECRET);
}