mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-22 12:50:22 -07:00
apt: remove deprecated installed/removed aliases (#55338)
* apt: remove deprecated installed/removed aliases Fixes #55311
This commit is contained in:
parent
9495ddbc21
commit
4ec8599c38
6 changed files with 7 additions and 14 deletions
|
@ -1003,7 +1003,7 @@ def get_cache(module):
|
|||
def main():
|
||||
module = AnsibleModule(
|
||||
argument_spec=dict(
|
||||
state=dict(type='str', default='present', choices=['absent', 'build-dep', 'installed', 'latest', 'present', 'removed', 'present', 'fixed']),
|
||||
state=dict(type='str', default='present', choices=['absent', 'build-dep', 'fixed', 'latest', 'present']),
|
||||
update_cache=dict(type='bool', aliases=['update-cache']),
|
||||
cache_valid_time=dict(type='int', default=0),
|
||||
purge=dict(type='bool', default=False),
|
||||
|
@ -1068,14 +1068,6 @@ def main():
|
|||
autoremove = p['autoremove']
|
||||
autoclean = p['autoclean']
|
||||
|
||||
# Deal with deprecated aliases
|
||||
if p['state'] == 'installed':
|
||||
module.deprecate("State 'installed' is deprecated. Using state 'present' instead.", version="2.9")
|
||||
p['state'] = 'present'
|
||||
if p['state'] == 'removed':
|
||||
module.deprecate("State 'removed' is deprecated. Using state 'absent' instead.", version="2.9")
|
||||
p['state'] = 'absent'
|
||||
|
||||
# Get the cache object
|
||||
cache = get_cache(module)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue