diff options
author | 2012-02-05 12:38:00 +0100 | |
---|---|---|
committer | 2012-02-05 13:10:44 +0100 | |
commit | 5cc1ce177fa52b7156dcf72176cb3be00108f58e (patch) | |
tree | 4fbf975258506657f2a559c2bc664ac18590b70d /pygithub3/resources | |
parent | Complete skeleton of services glueing to requests (diff) | |
download | python-github3-5cc1ce177fa52b7156dcf72176cb3be00108f58e.tar.xz python-github3-5cc1ce177fa52b7156dcf72176cb3be00108f58e.zip |
User service complete
User.emails
User.keys
User.followers
Diffstat (limited to 'pygithub3/resources')
-rw-r--r-- | pygithub3/resources/base.py | 2 | ||||
-rw-r--r-- | pygithub3/resources/users.py | 6 |
2 files changed, 7 insertions, 1 deletions
diff --git a/pygithub3/resources/base.py b/pygithub3/resources/base.py index 5a9418a..620df3e 100644 --- a/pygithub3/resources/base.py +++ b/pygithub3/resources/base.py @@ -60,7 +60,7 @@ class Resource(object): {attr: parse_date(raw_resource[attr]) for attr in self._dates if attr in raw_resource}) raw_resource.update( - {attr: parse_map(resource , raw_resource[attr]) + {attr: parse_map(resource, raw_resource[attr]) for attr, resource in self._maps.items() if attr in raw_resource}) raw_resource.update( diff --git a/pygithub3/resources/users.py b/pygithub3/resources/users.py index 7e40025..5485bf6 100644 --- a/pygithub3/resources/users.py +++ b/pygithub3/resources/users.py @@ -6,6 +6,12 @@ from .base import Resource __all__ = ('Plan', 'User') +class Key(Resource): + + def __str__(self): + return '<Key (%s)>' % getattr(self, 'title', '') + + class Plan(Resource): def __str__(self): |