TUSHAR2004
4 months ago
109
4
Laravel

Call to a member function connection() on null.

Posted 4 months ago by TUSHAR2004

Hi,

Whenever I delete the config.php file located in /bootstrap/cache folder my Laravel application breaks.

After that, if I try to run any artisan command or try to visit any page of my application it gives me the following error:

    Call to a member function connection() on null on 
         path\vendor\laravel\framework\src\Illuminate\Database\Eloquent\Model.php on line 1239

Does anybody know how to fix it?

Please sign in or create an account to participate in this conversation.