laravel-swagger icon indicating copy to clipboard operation
laravel-swagger copied to clipboard

support or update for laravel 8

Open ap-coder opened this issue 4 years ago • 1 comments

  • Laravel Swagger Version: dev-master
  • Laravel Version: 8
  • PHP Version: 8

Description:

First install says needs php 7.4 or higher but i have php8 i installed with --ignore-platform-req="mtrajano/laravel-swagger"

but when i try to generate i get the error below.

php artisan laravel-swagger:generate

   ErrorException

  Method ReflectionParameter::getClass() is deprecated

  at vendor/mtrajano/laravel-swagger/src/Generator.php:193
    189▕
    190▕         $parameters = $action_instance->getParameters();
    191▕
    192▕         foreach ($parameters as $parameter) {
  ➜ 193▕             $class = $parameter->getClass();
    194▕
    195▕             if (!$class) {
    196▕                 continue;
    197▕             }

      +18 vendor frames
  19  artisan:37
      Illuminate\Foundation\Console\Kernel::handle()

ap-coder avatar Jan 05 '21 17:01 ap-coder

@ap-coder Hi, I missed this issue yesterday for some reason. Looks like I posted a duplicate with #60

I also posted PR #61 to fix the deprecation error.

viki53 avatar Mar 10 '21 10:03 viki53