fix silly bugs

This commit is contained in:
Matt Cooper 2019-09-03 09:31:47 -04:00
parent 406d74c258
commit 7bbc9b1455
2 changed files with 2 additions and 2 deletions

View File

@ -5,4 +5,4 @@ import scrython
try: try:
search = scrython.cards.Search(q="!Black Lotus") search = scrython.cards.Search(q="!Black Lotus")
except scrython.ScryfallError as e: except scrython.ScryfallError as e:
print(str(e.status) + ' ' + e.code + ': ' + e.details) print(str(e.error_details['status']) + ' ' + e.error_details['code'] + ': ' + e.error_details['details'])

View File

@ -35,7 +35,7 @@ class FoundationObject(object):
loop.run_until_complete(main(loop)) loop.run_until_complete(main(loop))
if self.scryfallJson['object'] == 'error': if self.scryfallJson['object'] == 'error':
raise ScryfallError(self.scryfallJson, message=self.scryfallJson['details']) raise ScryfallError(self.scryfallJson, self.scryfallJson['details'])
def _checkForKey(self, key): def _checkForKey(self, key):
"""Checks for a key in the scryfallJson object. """Checks for a key in the scryfallJson object.