mirror of
https://github.com/nikdoof/test-auth.git
synced 2025-12-14 14:52:15 +00:00
Return not found on error jsondoc
This commit is contained in:
@@ -40,6 +40,9 @@ class RedditAccount(models.Model):
|
||||
except:
|
||||
raise self.DoesNotExist
|
||||
|
||||
if 'error' in jsondoc:
|
||||
raise self.DoesNotExist
|
||||
|
||||
data = jsondoc['data']
|
||||
|
||||
self.link_karma = int(data['link_karma'])
|
||||
|
||||
Reference in New Issue
Block a user