From 18475cc2575a807ebe901a911ec6bde780d5075d Mon Sep 17 00:00:00 2001 From: Nanda Scott Date: Tue, 6 Feb 2018 21:55:24 -0500 Subject: [PATCH] Added next_page and warnings to Search(). --- scrython/cards/search.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/scrython/cards/search.py b/scrython/cards/search.py index 669c6bb..aeb8858 100644 --- a/scrython/cards/search.py +++ b/scrython/cards/search.py @@ -41,3 +41,15 @@ class Search(ScryfallObject): return KeyError('This card has no associated data key.') return self.scryfallJson['data'] + + def next_page(self): + if self.__checkForKey('next_page') is None: + return KeyError('This card has no associated next page key.') + + return self.scryfallJson['next_page'] + + def warnings(self): + if self.__checkForKey('warnings') is None: + return KeyError('This card has no associated warnings key.') + + return self.scryfallJson['warnings']