-
-
Notifications
You must be signed in to change notification settings - Fork 1k
Description
Versions:
- laravel-modules Version: 11.0
- Laravel Version: 11.9
- PHP Version: 8.2
Description:
Hi
Im having an issue as on attached picture and code. It occurs when running pretty much any artisan or composer command in the repo. There doesn't seem to be a null passed to the method.

TypeError Nwidart\Modules\Module::getExtraPath(): Argument #1 ($path) must be of type string, null given, called in /mnt/c/Users/******/***/vendor/nwidart/laravel-modules/src/LaravelModulesServiceProvider.php on line 130
at vendor/nwidart/laravel-modules/src/Module.php:385 381▕ 382▕ /** 383▕ * Get extra path. 384▕ */ ➜ 385▕ public function getExtraPath(string $path): string 386▕ { 387▕ return $this->getPath().'/'.$path; 388▕ } 389
` 17 vendor frames
18 Modules/Downloads/app/Providers/RouteServiceProvider.php:47
19 Modules/Downloads/app/Providers/RouteServiceProvider.php:25
Modules\Downloads\Providers\RouteServiceProvider::mapApiRoutes() attached also the RouteServiceProviderFile that apparently issue occurs in
`<?php
namespace Modules\Downloads\Providers;
use Illuminate\Support\Facades\Route;
use Illuminate\Foundation\Support\Providers\RouteServiceProvider as ServiceProvider;
class RouteServiceProvider extends ServiceProvider
{
public function boot(): void
{
parent::boot();
}
public function map(): void
{
$this->mapApiRoutes();
// $this->mapWebRoutes();
}
// protected function mapWebRoutes(): void
// {
// Route::middleware('web')->group(module_path('Downloads', '/Routes/web.php'));
// }
protected function mapApiRoutes(): void
{
Route::middleware('api')->prefix('api')->name('api.')->group(module_path('Downloads', '/routes/api.php'));
} `
Steps To Reproduce:
Not sure what caused it.