0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

Laravelエラーの解決方法 メモ

Posted at

※随時追加していく

基本的にlaravel 6.x

##Seederでダミーデータ作成時

..実行したコマンド
php artisan db:seed --class=FooSeeder
..エラー
   Illuminate\Contracts\Container\BindingResolutionException  : Target class [FooSeeder] does not exist.

  at /var/www/project/vendor/laravel/framework/src/Illuminate/Container/Container.php:805
    801|
    802|         try {
    803|             $reflector = new ReflectionClass($concrete);
    804|         } catch (ReflectionException $e) {
  > 805|             throw new BindingResolutionException("Target class [$concrete] does not exist.", 0, $e);
    806|         }
    807|
    808|         // If the type is not instantiable, the developer is attempting to resolve
    809|         // an abstract type such as an Interface or Abstract Class and there is

  Exception trace:

  1   ReflectionException::("Class FooSeeder does not exist")
      /var/www/project/vendor/laravel/framework/src/Illuminate/Container/Container.php:803

  2   ReflectionClass::__construct()
      /var/www/project/vendor/laravel/framework/src/Illuminate/Container/Container.php:803

  Please use the argument -v to see more details.
..解決方法
composer dump-autoload
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?