Skip to content

Commit

Permalink
uri status_code elements are type int (ansible#72062)
Browse files Browse the repository at this point in the history
  • Loading branch information
sivel authored Oct 2, 2020
1 parent 2b79cd2 commit 0e480d3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 2 additions & 0 deletions changelogs/fragments/uri-status-code-int.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
bugfixes:
- uri - ``status_code`` elements are type ``int``
4 changes: 2 additions & 2 deletions lib/ansible/modules/uri.py
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@
description:
- A list of valid, numeric, HTTP status codes that signifies success of the request.
type: list
elements: str
elements: int
default: [ 200 ]
timeout:
description:
Expand Down Expand Up @@ -620,7 +620,7 @@ def main():
follow_redirects=dict(type='str', default='safe', choices=['all', 'no', 'none', 'safe', 'urllib2', 'yes']),
creates=dict(type='path'),
removes=dict(type='path'),
status_code=dict(type='list', elements='str', default=[200]),
status_code=dict(type='list', elements='int', default=[200]),
timeout=dict(type='int', default=30),
headers=dict(type='dict', default={}),
unix_socket=dict(type='path'),
Expand Down

0 comments on commit 0e480d3

Please sign in to comment.