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

Fixes #6875 - OpenAPI Schema inconsistent operationId casing #6876

merged 1 commit into from Sep 3, 2019


Copy link

@peterfarrell peterfarrell commented Aug 19, 2019


Fixes incorrect casing of operationId in OpenAPI generation - refs #6875. Specifically fixing ListThings to listThings which standardizes on lowerInitialCamelCase like the other method types.

Updated tests as well.

Copy link
Contributor Author

peterfarrell commented Aug 19, 2019

@carltongibson Fixed issue with casing also fixed edge cases where it incorrectly removed the "action" from the end of the name. If the view class was called AuthorRecreate, it would incorrectly build the operationId as createAuthorRe by stripping create was the action at the end when it's the end steam of Recreate. Used title() on the action to properly look at the camel-casing of the name to see if the action should be stripped from the end AuthorRecreate (put) -> createAuthorRecreate.

Ready for review.

Copy link

@carltongibson carltongibson left a comment

OK, super. Thanks @peterfarrell!

@carltongibson carltongibson merged commit b3f032f into encode:master Sep 3, 2019
1 check passed
pchiquet pushed a commit to pchiquet/django-rest-framework that referenced this pull request Nov 17, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
None yet

Successfully merging this pull request may close these issues.

None yet

2 participants