Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix custom type docs on "Intermediate usage" and docstring #434

Merged
merged 2 commits into from
May 3, 2015

Conversation

elatomo
Copy link
Contributor

@elatomo elatomo commented May 3, 2015

Both the intermediate usage example on custom types and the related docstrings in the Argument class are quite confussing for newcomers:

  • Returning an actual value instead of True draws a clearer picture of the expected behaviour one custom type.
  • Both the email example function and the Argument docstring reference a ValidationError exception which is not present on source and is actually not required (any raised exception will do for converting/validating types).

elatomo added 2 commits May 3, 2015 10:33
- Returning the same string instead of True draws a clearer picture of the expected behaviour of a custom type function.
- Replace 'ValidationError' with a built-in exception.
@joshfriend
Copy link
Member

Good catch, thanks!

joshfriend added a commit that referenced this pull request May 3, 2015
Fix custom type docs on "Intermediate usage" and docstring
@joshfriend joshfriend merged commit 0cbe85b into flask-restful:master May 3, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants