ClassName doesnot exist or Reflection Exception
You get a Class does not exist exception sometimes when running projects. Let's see such a case today. We are calling userTableSeeder.php from DatabaseSeeder.php and while running the
php artisan db:seedcommand you are getting a ReflectionException. We have given some information which could help you to avoid this type of error.
You have to include the controller in the namespace,
namespace App\Http\Controllers;
. When you make a migration, refresh the class map in composer.json file.
Run composer dump-autoload command.
composer dump-autoload
.Run the config command.
php artisan config:clearThis will give some information about the error.
If you want to add new .env variables make sure no spaces are there.
Comments
0 comments
Please Sign in or Create an account to Post Comments