| Total Complexity | 2 |
| Total Lines | 11 |
| Duplicated Lines | 0 % |
| 1 | from st2actions.runners.pythonrunner import Action |
||
| 6 | class LibratoBaseAction(Action): |
||
| 7 | def __init__(self, config): |
||
| 8 | super(LibratoBaseAction, self).__init__(config) |
||
| 9 | self.librato = self._get_client() |
||
| 10 | |||
| 11 | def _get_client(self): |
||
| 12 | user = self.config['user'] |
||
| 13 | token = self.config['token'] |
||
| 14 | |||
| 15 | client = librato.connect(user, token) |
||
| 16 | return client |
||
| 17 |