1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

Use correct variable name.

This commit is contained in:
Nando Vieira 2015-07-27 01:45:03 -03:00 committed by Matt Clay
parent c6391741a2
commit 236b2d5c0d

View file

@ -96,13 +96,9 @@ def send_msg(module, token, room, msg_from, msg, msg_format='text',
params['message_format'] = msg_format
params['color'] = color
params['api'] = api
params['notify'] = int(notify)
if notify:
params['notify'] = 1
else:
params['notify'] = 0
url = api + "?auth_token=%s" % (token)
url = api + MSG_URI_V1 + "?auth_token=%s" % (token)
data = urllib.urlencode(params)
if module.check_mode:
@ -127,7 +123,7 @@ def send_msg_v2(module, token, room, msg_from, msg, msg_format='text',
body['message'] = msg
body['color'] = color
body['message_format'] = msg_format
params['notify'] = notify
body['notify'] = notify
POST_URL = api + NOTIFY_URI_V2