diff --git a/.gitignore b/.gitignore index 9e55f78..8241ea8 100644 --- a/.gitignore +++ b/.gitignore @@ -43,6 +43,10 @@ output/*/index.html docs/_build .ropeproject +# pyenv +.python-version + # Generated test charms cloudfoundry-r* output-v*.yaml + diff --git a/charmhelpers/core/services/helpers.py b/charmhelpers/core/services/helpers.py index 4b90589..8d1af74 100644 --- a/charmhelpers/core/services/helpers.py +++ b/charmhelpers/core/services/helpers.py @@ -45,7 +45,7 @@ def is_ready(self): """ Returns True if all of the `required_keys` are available from any units. """ - ready = len(self.get(self.name, [])) > 0 + ready = !!self.get(self.name, []) if not ready: hookenv.log('Incomplete relation: {}'.format(self.__class__.__name__), hookenv.DEBUG) return ready