Skip to content
Browse files

Make configurator properly filter by test name.

  • Loading branch information...
1 parent 8b08153 commit 3ca9ccf66ac2ccc516c2af1f1edfb580c50cde09 Mike Cooper committed
Showing with 4 additions and 2 deletions.
  1. +4 −2 railroad/railroad/viewhosts/views.py
View
6 railroad/railroad/viewhosts/views.py
@@ -326,7 +326,9 @@ def get_graphs(stat, obj, hosts='', groups='', services='', tests='',
service_list = new_services
if tests:
- filter(lambda x: x['nagcat_template'] in tests, service_list)
+ service_list = filter(
+ lambda x: x.get('nagcat_template', None) in tests,
+ service_list)
# Find out whether each service object is graphable or not
for service in service_list:
@@ -639,7 +641,7 @@ def real_meta(hosts='', services='', groups='', tests=''):
response = []
graph_template = loader.get_template('graph.html')
- for graph in get_graphs(stat, obj, hosts, groups, services):
+ for graph in get_graphs(stat, obj, hosts, groups, services, tests):
so = {
'host': graph['host_name'],

0 comments on commit 3ca9ccf

Please sign in to comment.
Something went wrong with that request. Please try again.