php artisan package:discover laravel project composer install

Why am I geting this error when I try to run composer install on my laravel project?

Illuminate\Foundation\ComposerScripts::postAutoloadDump @php artisan package:discover

In Request.php line 277:

Class 'Symfony\Component\HttpFoundation\FileBag' not found

Script @php artisan package:discover handling the post-autoload-dump event returned with error code 1