Permalink
Browse files

Fixed a wrong example in the view docs. This fixes #374

  • Loading branch information...
1 parent 065afe5 commit b6625ec19329031ddb26dec63c6bd0477a00bf22 @mitsuhiko mitsuhiko committed Jan 4, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 docs/views.rst
View
@@ -223,7 +223,7 @@ registration code::
app.add_url_rule(url, defaults={pk: None},
view_func=view_func, methods=['GET',])
app.add_url_rule(url, view_func=view_func, methods=['POST',])
- app.add_url_rule('%s<%s:%s>' % (url, pk, pk_type), view_func=view_func,
+ app.add_url_rule('%s<%s:%s>' % (url, pk_type, pk), view_func=view_func,
methods=['GET', 'PUT', 'DELETE'])
register_api(UserAPI, 'user_api', '/users/', pk='user_id')

0 comments on commit b6625ec

Please sign in to comment.