Skip to content
This repository was archived by the owner on Mar 15, 2021. It is now read-only.

Commit

Permalink
Modify blueprint.list to return an empty list to fix #4
Browse files Browse the repository at this point in the history
  • Loading branch information
sammcgeown committed Dec 17, 2019
1 parent c7ec3c0 commit 80ad69e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
5 changes: 4 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
.vscode
__pycache__
*.pyc
*.pyc
build
caspyr.egg-info
dist
4 changes: 3 additions & 1 deletion caspyr/blueprint.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,9 @@ def list(session):

uri = '/blueprint/api/blueprints/'
j = session._request(f'{session.baseurl}{uri}')
return j['objects']
if 'objects' in j:
return j['objects']
return []

@classmethod
def describe(cls, session, blueprint_id):
Expand Down

0 comments on commit 80ad69e

Please sign in to comment.