Fix trust key 2015.8 (#36540)

* Fix gpg.trust_key user bug

* Separated user and no user case
This commit is contained in:
elainearbaugh 2016-09-27 09:28:28 -07:00 committed by Nicole Thomas
parent 57ec792f6b
commit 6e36191fc4

View file

@ -811,7 +811,10 @@ def trust_key(keyid=None,
if not fingerprint:
if keyid:
key = get_key(keyid)
if user:
key = get_key(keyid, user=user)
else:
key = get_key(keyid)
if key:
if 'fingerprint' not in key:
ret['res'] = False