-
Notifications
You must be signed in to change notification settings - Fork 937
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
Call to undefined method [SomeAnnotation]::isRoot() #1415
Comments
Have you tried upgrading swagger-php ? I tried creating a testcase and it looks like the latest code should be ok with this. |
Sorry, I should have provided better example. <?php
require "vendor/autoload.php";
use OpenApi\Annotations as OA;
/**
* @Annotation
*/
class CustomAnnotation {}
/**
* @OA\Schema
* @CustomAnnotation
*/
class SomeParent {}
/**
* @OA\Schema
*/
class Child extends SomeParent {}
$generator = new \OpenApi\Generator();
$generator->generate([
__FILE__
]); |
Interesting - things change depending on whether there is a namespace used or not 🧇 |
Thank you for the quick fix! 🙂 |
FYI this is also happening in
|
I am not sure what is going on there - |
@DerManoMann You are correct, the function should be there but isn't... something went haywire with my vendor folder, re-installed everything and it works. |
This can happen if you have a different annotation on an
@OA\Schema
.The line in Analysis seems to just assume that all annotations on the class has the
isRoot
method.Seems to be related to e449670 #1403
The text was updated successfully, but these errors were encountered: