mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Avoid Early Convert ret['comment'] to String
Fixes this exception: An exception occurred in this state: Traceback (most recent call last): File "/var/tmp/.syops_b1274f_salt/py2/salt/state.py", line 1733, in call **cdata['kwargs']) File "/var/tmp/.syops_b1274f_salt/py2/salt/loader.py", line 1652, in wrapper return f(*args, **kwargs) File "/var/tmp/.syops_b1274f_salt/py2/salt/states/gpg.py", line 119, in present ret['comment'].append('Adding {0} to GPG keychain'.format(name)) AttributeError: 'str' object has no attribute 'append'
This commit is contained in:
parent
8c0a83cbb5
commit
01addb6053
1 changed files with 2 additions and 2 deletions
|
@ -132,7 +132,7 @@ def present(name,
|
|||
else:
|
||||
ret['comment'].append('Invalid trust level {0}'.format(trust))
|
||||
|
||||
ret['comment'] = '\n'.join(ret['comment'])
|
||||
ret['comment'] = '\n'.join(ret['comment'])
|
||||
return ret
|
||||
|
||||
|
||||
|
@ -188,5 +188,5 @@ def absent(name,
|
|||
ret['comment'].append('Deleting {0} from GPG keychain'.format(name))
|
||||
else:
|
||||
ret['comment'].append('{0} not found in GPG keychain'.format(name))
|
||||
ret['comment'] = '\n'.join(ret['comment'])
|
||||
ret['comment'] = '\n'.join(ret['comment'])
|
||||
return ret
|
||||
|
|
Loading…
Add table
Reference in a new issue