Dagger List cmd : change error message to a more verbose one

Signed-off-by: Guillaume de Rouville <guillaume.derouville@gmail.com>
This commit is contained in:
Guillaume de Rouville 2021-06-01 21:16:07 +02:00
parent 7d740fb255
commit 42624ed737

View File

@ -131,6 +131,9 @@ func Decrypt(_ context.Context, encrypted []byte) ([]byte, error) {
}
key, err := tree.Metadata.GetDataKey()
if err != nil {
if userErr, ok := err.(sops.UserError); ok {
err = fmt.Errorf(userErr.UserError())
}
return nil, err
}