On Friday everything was working well. Today I returned and I ran the command " php artisan serve " and gives me this error
Fatal error: Class 'Illuminate\Foundation\Console\Kernel' not found in C:\Users\NERS\Docs\CSM Portal\app\Console\Kernel.php on line 9
I ran the command "composer dump-autoload and nothing. My app.php file is fine I think
Whats the problem?
APP.php file:
<?php
$app = new Illuminate\Foundation\Application(
realpath(__DIR__.'/../')
);
$app->singleton(
Illuminate\Contracts\Http\Kernel::class,
App\Http\Kernel::class
);
$app->singleton(
Illuminate\Contracts\Console\Kernel::class,
App\Console\Kernel::class
);
$app->singleton(
Illuminate\Contracts\Debug\ExceptionHandler::class,
App\Exceptions\Handler::class
);
return $app;
COMPOSER.json file:
{
"name": "laravel/laravel",
"description": "The Laravel Framework.",
"keywords": ["framework", "laravel"],
"license": "MIT",
"type": "project",
"require": {
"khill/lavacharts" : "3.0.*",
"php": ">=5.5.9",
"laravel/framework": "5.2.*",
"twbs/bootstrap": "^3.3",
"phpexcel/phpexcel": "dev-master",
"barryvdh/laravel-dompdf": "0.6.*"
},
"require-dev": {
"fzaninotto/faker": "~1.4",
"mockery/mockery": "0.9.*",
"phpunit/phpunit": "~4.0",
"symfony/css-selector": "2.8.*|3.0.*",
"symfony/dom-crawler": "2.8.*|3.0.*"
},
"autoload": {
"classmap": [
"database"
],
"psr-4": {
"App\\": "app/"
}
},
"autoload-dev": {
"classmap": [
"tests/TestCase.php"
]
},
"scripts": {
"post-root-package-install": [
"php -r \"copy('.env.example', '.env');\""
],
"post-create-project-cmd": [
"php artisan key:generate"
],
"post-install-cmd": [
"Illuminate\\Foundation\\ComposerScripts::postInstall",
"php artisan optimize"
],
"post-update-cmd": [
"Illuminate\\Foundation\\ComposerScripts::postUpdate",
"php artisan optimize"
]
},
"config": {
"preferred-install": "dist"
}
}
Well, I deleted the vendor folder and ran the command "composer install" and its working again :D
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community