From 963b9f8ff6e701837c63e4ca0cf5f6545ccd96fc Mon Sep 17 00:00:00 2001 From: Artyom Jaksov Date: Thu, 17 Oct 2024 17:39:06 +0200 Subject: [PATCH] simpify ConnectionRepository --- Model/Config/System/ConnectionRepository.php | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/Model/Config/System/ConnectionRepository.php b/Model/Config/System/ConnectionRepository.php index cdc6f8e..b3459e3 100644 --- a/Model/Config/System/ConnectionRepository.php +++ b/Model/Config/System/ConnectionRepository.php @@ -114,11 +114,8 @@ private function getCacheEncryptionKey(?int $storeId = null): ?string { $path = self::XML_PATH_CACHE_ENCRYPTION_KEY; $value = $this->getStoreValue($path, $storeId); - if (is_string($value)) { - if ($value) { - return $this->encryptor->decrypt($value); - } - return ''; + if (!empty($value)) { + return $this->encryptor->decrypt($value); } return null; }