8000 Also put json.get in the json is not None check · staticdev/github4.py@f748d7b · GitHub
[go: up one dir, main page]

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

Commit f748d7b

Browse files
committed
Also put json.get in the json is not None check
1 parent e09add9 commit f748d7b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

github3/models.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,9 @@ def __init__(self, json):
2929
if json is not None:
3030
self.etag = json.pop('ETag', None)
3131
self.last_modified = json.pop('Last-Modified', None)
32+
self._uniq = json.get('url', None)
3233
self._json_data = json
33-
self._uniq = json.get('url', None)
34-
34+
3535
def to_json(self):
3636
"""Return the json representing this object."""
3737
return self._json_data

0 commit comments

Comments
 (0)
0