-
-
Notifications
You must be signed in to change notification settings - Fork 528
Collection methods are added to the supported entity methods #1105
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
Labels
bug
Something isn't working
Comments
I have added a fix for it. |
This was referenced Mar 16, 2021
Closed
Closed
This was referenced Mar 17, 2021
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Describe the bug
When disabling all single entity access methods and only allowing whole collection endpoints like in the repository bellow. Spring doc will still show a GET method endpoint for a single entity via an ID. The corresponding endpoint will return 405 (Method not allowed) because it is disabled.
generated yaml:
To Reproduce
Using springdoc 1.5.4
Expected behavior
Because the single entity methods are disabled it should not be added to the docs.
Additional context
The endpoint is considered enabled because the collection methods are added to the item access methods.
springdoc-openapi/springdoc-openapi-data-rest/src/main/java/org/springdoc/data/rest/core/DataRestRouterOperationService.java
Lines 170 to 173 in 60e0512
I lack the insight of why this is done in the first place.
The text was updated successfully, but these errors were encountered: