Permalink
Browse files

Merge pull request #1086 from graingert/patch-2

Update the link headers doc to match the code
  • Loading branch information...
kennethreitz committed Jan 7, 2013
2 parents 50934e0 + 7dc13e5 commit 21616a815b93bc4074c43f2f290c1de571169e23
Showing with 4 additions and 4 deletions.
  1. +4 −4 docs/user/advanced.rst
View
@@ -480,9 +480,9 @@ GitHub uses these for `pagination <http://developer.github.com/v3/#pagination>`_
Requests will automatically parse these link headers and make them easily consumable::
- >>> r.links['next']
- 'https://api.github.com/users/kennethreitz/repos?page=2&per_page=10'
+ >>> r.links["next"]
+ {'url': 'https://api.github.com/users/kennethreitz/repos?page=2&per_page=10', 'rel': 'next'}
- >>> r.links['last']
- 'https://api.github.com/users/kennethreitz/repos?page=6&per_page=10'
+ >>> r.links["last"]
+ {'url': 'https://api.github.com/users/kennethreitz/repos?page=7&per_page=10', 'rel': 'last'}

0 comments on commit 21616a8

Please sign in to comment.