Cristal
Cristal

Reputation: 502

Laravel error on php artisan serve

Error on php artisan serve

PHP Fatal error: Uncaught exception ReflectionException with message

Class App\Console\Kernel does not exist in 
/home/blog/vendor/laravel/framework/src/Illuminate/
Container/Container.php:719
Stack trace:
#0 /home/blog/vendor/laravel/framework/src/Illuminate/Container/
Container.php(719): ReflectionClass->__construct(App\\Console\\Ker...)
#1 /home/blog/vendor/laravel/framework/src/Illuminate/Container/
Container.php(598): 
Illuminate\Container\Container->build(App\\Console\\Ker...)

P.S. Class App\Console\Kernel does exist

Upvotes: 1

Views: 757

Answers (2)

apokryfos
apokryfos

Reputation: 40653

Not sure if laravel supports having the App folder under anything.

At any rate this may or may not work:

Change in composer.json:

"psr-4": {
        "App\\": "resources/app/",

Run composer dump-autoload

Composer install or update should also work in refreshing the autoloader.

I would highly discourage you placing the app folder under resources. That's not what the resources folder is supposed to contain.

Upvotes: 1

Viktor
Viktor

Reputation: 827

I more hint. You can remove cache manually and vandor folder also, than run composer install. This should help.

Upvotes: 0

Related Questions