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

Refactor strategy determining the root annotation in a context #1227

Merged
merged 2 commits into from
May 8, 2022

Conversation

DerManoMann
Copy link
Collaborator

@DerManoMann DerManoMann commented May 6, 2022

Fixes #1226

This changes the way the code determines what is the root annotation in a context. The proposed new way is that an annotation is the root if:

  • it is the only annotation
  • it is the best match of being an instance or subclass of one of these classes (in priority order)
    • OA\Operation
    • OA\Property
    • OA\Parameter
      or (lowest priority) of type OpenApi\Annotations\Schemaor OpenApi\Attributes\Schema. In this case the exact class is required.

@DerManoMann DerManoMann force-pushed the attribute-comments branch from d59d1e2 to 1468379 Compare May 6, 2022 09:15
@DerManoMann DerManoMann merged commit e4f5305 into zircote:master May 8, 2022
@DerManoMann DerManoMann deleted the attribute-comments branch May 8, 2022 21:39
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.

docblock comments inconsistent using attributes
1 participant