mirror of
https://github.com/valitydev/salt.git
synced 2024-11-08 09:23:56 +00:00
Move check for rtag to outermost-nesting in function
This commit is contained in:
parent
ac67c6b493
commit
340110b4b4
@ -1228,10 +1228,7 @@ def installed(
|
|||||||
reinstall=reinstall,
|
reinstall=reinstall,
|
||||||
normalize=normalize,
|
normalize=normalize,
|
||||||
**kwargs)
|
**kwargs)
|
||||||
|
|
||||||
refreshed = refreshed or refresh
|
refreshed = refreshed or refresh
|
||||||
if os.path.isfile(rtag) and refreshed:
|
|
||||||
os.remove(rtag)
|
|
||||||
except CommandExecutionError as exc:
|
except CommandExecutionError as exc:
|
||||||
ret = {'name': name,
|
ret = {'name': name,
|
||||||
'changes': {},
|
'changes': {},
|
||||||
@ -1287,6 +1284,9 @@ def installed(
|
|||||||
failed_hold = [hold_ret[x] for x in hold_ret
|
failed_hold = [hold_ret[x] for x in hold_ret
|
||||||
if not hold_ret[x]['result']]
|
if not hold_ret[x]['result']]
|
||||||
|
|
||||||
|
if os.path.isfile(rtag) and refreshed:
|
||||||
|
os.remove(rtag)
|
||||||
|
|
||||||
if to_unpurge:
|
if to_unpurge:
|
||||||
changes['purge_desired'] = __salt__['lowpkg.unpurge'](*to_unpurge)
|
changes['purge_desired'] = __salt__['lowpkg.unpurge'](*to_unpurge)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user