Handle empty datadog_monitor message (#3468)

Since message is not required, it may be of type None, which cannot have
a replace() called on it.
pull/18777/head
Jesse Keating 8 years ago committed by Matt Clay
parent 7e6fe97f57
commit f6e47e4055

@ -197,7 +197,9 @@ def main():
unmute_monitor(module)
def _fix_template_vars(message):
return message.replace('[[', '{{').replace(']]', '}}')
if message:
return message.replace('[[', '{{').replace(']]', '}}')
return message
def _get_monitor(module):

Loading…
Cancel
Save