diff --git a/core/simplecrypt.class.inc.php b/core/simplecrypt.class.inc.php index 0be60cf20..170ddbe20 100644 --- a/core/simplecrypt.class.inc.php +++ b/core/simplecrypt.class.inc.php @@ -130,15 +130,13 @@ class SimpleCrypt */ function Decrypt($key, $string) { - try{ - return $this->oEngine->Decrypt($key,$string); - } catch(\Exception $e){ - if (strlen($string)==0){ - IssueLog::Warning("Cannot decrypt empty/null value", null, ['msg' => $e->getMessage(), 'stack' => $e->getTraceAsString()]); - return $string; - } - throw $e; - } + if (is_null($string) || strlen($string) == 0) { + IssueLog::Warning("Cannot decrypt empty/null value"); + + return $string; + } + + return $this->oEngine->Decrypt($key, $string); } /**