Skip to content

Added marshal_with_field decorator, see issue #212 #214

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

Merged
merged 4 commits into from
Apr 17, 2014

Conversation

lyschoening
Copy link
Contributor

I've added a new decorator for marshalling with a single field as requested in #212. Use cases are methods that return either a list or a single item.

I went with marshal_with_field as the name for the decorator; another name might be more suitable.

I've also edited the internals of the List field so that the formatting actually happens in the format() function rather than only in output().

@dougblack
Copy link
Contributor

@lyschoening I like it. Thanks for contributing!

dougblack added a commit that referenced this pull request Apr 17, 2014
Added marshal_with_field decorator, see issue #212
@dougblack dougblack merged commit 4f0b18b into flask-restful:master Apr 17, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants