Pep8 fixes for jira (#24229)

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
This commit is contained in:
Abhijeet Kasurde 2017-05-03 12:46:20 +05:30 committed by John R Barker
parent b6b3f84990
commit 53f0cd197e
2 changed files with 20 additions and 16 deletions

View file

@ -247,6 +247,7 @@ from ansible.module_utils.basic import *
from ansible.module_utils.urls import *
from ansible.module_utils.pycompat24 import get_exception
def request(url, user, passwd, timeout, data=None, method=None):
if data:
data = json.dumps(data)
@ -273,12 +274,15 @@ def request(url, user, passwd, timeout, data=None, method=None):
else:
return {}
def post(url, user, passwd, timeout, data):
return request(url, user, passwd, timeout, data=data, method='POST')
def put(url, user, passwd, timeout, data):
return request(url, user, passwd, timeout, data=data, method='PUT')
def get(url, user, passwd, timeout):
return request(url, user, passwd, timeout)
@ -357,6 +361,7 @@ def transition(restbase, user, passwd, params):
return ret
def link(restbase, user, passwd, params):
data = {
'type': {'name': params['linktype']},
@ -378,6 +383,7 @@ OP_REQUIRED = dict(create=['project', 'issuetype', 'summary', 'description'],
transition=['status'],
link=['linktype', 'inwardissue', 'outwardissue'])
def main():
global module
@ -440,7 +446,6 @@ def main():
e = get_exception()
return module.fail_json(msg=e.message)
module.exit_json(changed=True, meta=ret)

View file

@ -770,7 +770,6 @@ lib/ansible/modules/web_infrastructure/ansible_tower/tower_user.py
lib/ansible/modules/web_infrastructure/deploy_helper.py
lib/ansible/modules/web_infrastructure/ejabberd_user.py
lib/ansible/modules/web_infrastructure/jboss.py
lib/ansible/modules/web_infrastructure/jira.py
lib/ansible/modules/windows/win_disk_image.py
lib/ansible/modules/windows/win_dns_client.py
lib/ansible/modules/windows/win_domain.py