From ed5eb3a3c5bce1ed793ce0bd39d292659fe690e7 Mon Sep 17 00:00:00 2001 From: Pooya Parsa Dadashi Date: Tue, 1 Oct 2024 18:47:03 +0330 Subject: [PATCH] test: restore empty for test --- system/Encryption/Handlers/SodiumHandler.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/system/Encryption/Handlers/SodiumHandler.php b/system/Encryption/Handlers/SodiumHandler.php index 95653c087c26..193d064e0dea 100644 --- a/system/Encryption/Handlers/SodiumHandler.php +++ b/system/Encryption/Handlers/SodiumHandler.php @@ -42,7 +42,7 @@ public function encrypt($data, $params = null) { $this->parseParams($params); - if ($this->key === null) { + if (empty($this->key)) { throw EncryptionException::forNeedsStarterKey(); } @@ -73,7 +73,7 @@ public function decrypt($data, $params = null) { $this->parseParams($params); - if ($this->key === null) { + if (empty($this->key)) { throw EncryptionException::forNeedsStarterKey(); }