Skip to content

Commit

Permalink
Merge pull request #70 from PengfeiLi0218/master
Browse files Browse the repository at this point in the history
  • Loading branch information
simonredfern authored Jan 29, 2019
2 parents b02eb0a + c515a82 commit ca2fe60
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions apimanager/metrics/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,10 @@ def get_metrics(self, cleaned_data):
metrics = self.to_django(metrics['metrics'])
except APIError as err:
error_once_only(self.request, err)
except KeyError as err:
error_once_only(self.request, metrics['message'])
except:
error_once_only(self.request, 'Unknown Error')
return metrics

def get_context_data(self, **kwargs):
Expand Down

0 comments on commit ca2fe60

Please sign in to comment.