Add missing args param.

This commit is contained in:
Jimmy Zelinskie 2014-11-30 17:46:24 -05:00
parent bd9f529e38
commit 4f5a78ca2c

View file

@ -694,11 +694,13 @@ class StarredRepositoryList(ApiResource):
@parse_args
@query_param('page', 'Offset page number. (int)', type=int)
@query_param('limit', 'Limit on the number of results (int)', type=int)
def get(self):
def get(self, args):
""" List all starred repositories. """
page = args['page']
limit = args['limit']
starred_repos = list(get_user_starred_repositories(get_authenticated_user(), page=page, limit=limit))
starred_repos = list(model.get_user_starred_repositories(get_authenticated_user(),
page=page,
limit=limit))
return {'repositories': [repo_view(repo) for repo in starred_repos]}
@require_scope(scopes.READ_REPO)