fix(db): handle decryption error EE-2466 (#6499)

pull/6511/head
andres-portainer 2022-02-01 11:48:26 -03:00 committed by GitHub
parent cf459a2d28
commit 1bb02eea59
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -37,7 +37,7 @@ func (connection *DbConnection) UnmarshalObject(data []byte, object interface{})
if connection.getEncryptionKey() != nil {
data, err = decrypt(data, connection.getEncryptionKey())
if err != nil {
errors.Wrapf(err, "Failed decrypting object")
return errors.Wrap(err, "Failed decrypting object")
}
}
e := json.Unmarshal(data, object)