Module: check_mk
Branch: master
Commit: 583f1d8c55e0365a4ebd3a616bc981a0af516f1b
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=583f1d8c55e036…
Author: Ronny Bruska <rb(a)mathias-kettner.de>
Date: Sat Mar 9 16:22:58 2019 +0100
Fixed TypeError and return code
A TypeError was fixed.
Also the return code for disabled option of issue resolution was changed to 0.
Change-Id: I122857e32d122fab65b36f152bb2b6029b9e197f
---
cmk/notification_plugins/jira_issues.py | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/cmk/notification_plugins/jira_issues.py
b/cmk/notification_plugins/jira_issues.py
index da3e2e1..2182302 100644
--- a/cmk/notification_plugins/jira_issues.py
+++ b/cmk/notification_plugins/jira_issues.py
@@ -71,7 +71,7 @@ def main():
custom_field_value = int(context['SERVICEPROBLEMID'])
context['SUBJECT'] = utils.substitute_context(summary, context)
- label = context.get['PARAMETER_LABEL'] or tmpl_label
+ label = context.get('PARAMETER_LABEL') or tmpl_label
newissue = {
u'labels': [label],
u'summary': context['SUBJECT'],
@@ -134,8 +134,8 @@ def main():
if context['NOTIFICATIONTYPE'] == 'RECOVERY' and
custom_field_exists:
if "PARAMETER_RESOLUTION" not in context:
sys.stderr.write(
- "Ticket resolution not enabled in wato rule. Don't send a
resolution to jira")
- return 2
+ "Ticket resolution not enabled in wato rule. Don't send a
resolution to jira\n")
+ return 0
else:
resolution = None
if 'PARAMETER_RESOLUTION' in context: