Fix --decrypt command line option
This patch fixes the --decrypt flag when retrieving a secret. Change-Id: Ie36a4522e984447653b54130ba466222566ed5da Closes-Bug: #1434629
This commit is contained in:
parent
4bfc836aec
commit
278398584e
|
@ -52,10 +52,10 @@ class GetSecret(show.ShowOne):
|
|||
|
||||
def take_action(self, args):
|
||||
if args.decrypt:
|
||||
entity = self.app.client.secrets.decrypt(args.URI,
|
||||
args.payload_content_type)
|
||||
return (('Secret',),
|
||||
(entity,))
|
||||
entity = self.app.client.secrets.get(args.URI,
|
||||
args.payload_content_type)
|
||||
return (('Payload',),
|
||||
(entity.payload,))
|
||||
else:
|
||||
entity = self.app.client.secrets.get(secret_ref=args.URI)
|
||||
return entity._get_formatted_entity()
|
||||
|
|
Loading…
Reference in New Issue