diff --git a/stackalytics/dashboard/decorators.py b/stackalytics/dashboard/decorators.py index bc4bd0c35..19e3854e6 100644 --- a/stackalytics/dashboard/decorators.py +++ b/stackalytics/dashboard/decorators.py @@ -409,7 +409,7 @@ def templated(template=None, return_code=200): # put parameters into template ctx['metric'] = parameters.get_single_parameter( kwargs, 'metric', use_default=True) - ctx['metric_label'] = parameters.METRIC_LABELS[ctx['metric']] + ctx['metric_label'] = parameters.METRIC_LABELS.get(ctx['metric']) project_type = parameters.get_single_parameter( kwargs, 'project_type', use_default=True) diff --git a/stackalytics/dashboard/templates/reports/members.html b/stackalytics/dashboard/templates/reports/members.html index 50beeed5b..2c353e1c7 100644 --- a/stackalytics/dashboard/templates/reports/members.html +++ b/stackalytics/dashboard/templates/reports/members.html @@ -216,7 +216,7 @@ show_engineers_table(base_options); - {% if company == '' %} + {% if not company %} show_companies_table(base_options); show_new_companies_table(base_options); renderChart("/api/1.0/stats/companies", "members_chart", base_options);