3
4

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 5 years have passed since last update.

laravel Uncaught ReflectionException: Class config does not exist

Posted at

Uncaught ReflectionException: Class config does not exist

class "config" がないらしい。小文字だし。なにこれ。

dump-autoloadすると治ることがあるらしい

composer dump-autoload

こっちでもいい

composer dump-autoload -o

キャッシュをクリアしたら別のエラーが

Uncaught TypeError: Argument 2 passed to Illuminate\Routing\UrlGenerator::__construct() must be an instance of Illuminate\Http\Request

結論

こちらよりも、artisanコマンドを実行した際に出るこのエラーが問題。

Uncaught TypeError: Argument 2 passed to Illuminate\Routing\UrlGenerator::__construct() must be an instance of Illuminate\Http\Request

これが、キャッシュによって起こってた。
キャッシュ消せば解決。

composer update した直後とかだったから、謎に困った。

Laravelのキャッシュを削除する

3
4
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
3
4

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?