From 54e4311d1bdf4e44635b220e9bfdfba5c75c34fa Mon Sep 17 00:00:00 2001 From: Martyn Inglis Date: Mon, 22 Aug 2016 16:56:43 +0100 Subject: [PATCH] Merged in the defensive code by mistake --- app/notify_client/template_statistics_api_client.py | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/app/notify_client/template_statistics_api_client.py b/app/notify_client/template_statistics_api_client.py index e1965166f..7829340d2 100644 --- a/app/notify_client/template_statistics_api_client.py +++ b/app/notify_client/template_statistics_api_client.py @@ -17,16 +17,11 @@ class TemplateStatisticsApiClient(BaseAPIClient): if limit_days is not None: params['limit_days'] = limit_days - response = self.get( + return self.get( url='/service/{}/template-statistics'.format(service_id), params=params )['data'] - if len(response) > 0 and 'template' in response[0]: - return response - - return [] - def get_template_statistics_for_template(self, service_id, template_id): return self.get(