beyondcode / laravel-self-diagnosis

Perform Self-Diagnosis Tests On Your Laravel Application

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Laravel 7.0.x - Dotenv\Dotenv::__construct() must implement interface Dotenv\Loader\LoaderInterface, string given, called in ExampleEnvironmentVariablesAreSet.php on line 36

adiwit-co-th opened this issue · comments

Laravel 7.0.x with DotEnv 4.0.x compatibility issue

$ php artisan self-diagnosis
|-------------------------------------
| Common Checks
|-------------------------------------
Running check 1/11: App key is set...  ✔
Running check 2/11: The correct PHP version is installed...  ✔
Running check 3/11: The database can be accessed...  ✔
Running check 4/11: All directories have the correct permissions...  ✔
Running check 5/11: The environment file exists...  ✔
Running check 6/11: The example environment variables are set...  
   TypeError 

  Argument 1 passed to Dotenv\Dotenv::__construct() must implement interface Dotenv\Loader\LoaderInterface, string given, called in .../vendor/beyondcode/laravel-self-diagnosis/src/Checks/ExampleEnvironmentVariablesAreSet.php on line 36
at vendor/vlucas/phpdotenv/src/Dotenv.php:45
    41|      * @param \Dotenv\Store\StoreInterface|string[]  $store
    42|      *
    43|      * @return void
    44|      */
  > 45|     public function __construct(LoaderInterface $loader, RepositoryInterface $repository, $store)
    46|     {
    47|         $this->loader = $loader;
    48|         $this->repository = $repository;
    49|         $this->store = is_array($store) ? new FileStore($store, true) : $store;

      +18 vendor frames 
  19  artisan:37
      Illuminate\Foundation\Console\Kernel::handle(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))