RabbitMQ 3.6.7 changed a couple of response codes (#22715) (#25484)

(cherry picked from commit 6bd1681203)
pull/25485/head
John R Barker 9 years ago committed by GitHub
parent 8455251bec
commit c5971f018f

@ -204,7 +204,8 @@ def main():
elif module.params['state'] == 'absent':
r = requests.delete( url, auth = (module.params['login_user'],module.params['login_password']))
if r.status_code == 204:
# RabbitMQ 3.6.7 changed this response code from 204 to 201
if r.status_code == 204 or r.status_code == 201:
module.exit_json(
changed = True,
name = module.params['name']

@ -250,7 +250,8 @@ def main():
elif module.params['state'] == 'absent':
r = requests.delete( url, auth = (module.params['login_user'],module.params['login_password']))
if r.status_code == 204:
# RabbitMQ 3.6.7 changed this response code from 204 to 201
if r.status_code == 204 or r.status_code == 201:
module.exit_json(
changed = True,
name = module.params['name']

Loading…
Cancel
Save