From 1886ef40f1f94d484194fc9f3609ca6b6e43eaf1 Mon Sep 17 00:00:00 2001 From: Brent Langston Date: Sat, 22 Mar 2014 13:56:49 -0400 Subject: [PATCH] Make the default URI a constant --- notification/hipchat | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/notification/hipchat b/notification/hipchat index 86e3f1092da..4ff95b32bf6 100644 --- a/notification/hipchat +++ b/notification/hipchat @@ -75,8 +75,10 @@ EXAMPLES = ''' # HipChat module specific support methods. # +MSG_URI = "https://api.hipchat.com/v1/rooms/message" + def send_msg(module, token, room, msg_from, msg, msg_format='text', - color='yellow', notify=False, api='https://api.hipchat.com/v1/rooms/message'): + color='yellow', notify=False, api=MSG_URI): '''sending message to hipchat''' params = {} @@ -118,7 +120,7 @@ def main(): msg_format=dict(default="text", choices=["text", "html"]), notify=dict(default=True, type='bool'), validate_certs = dict(default='yes', type='bool'), - api = dict(default='https://api.hipchat.com/v1/rooms/message'), + api = dict(default=MSG_URI), ), supports_check_mode=True )