Laravel 8 Target class [xxxController] does not exist. HATA ÇÖZÜMÜ

hata kodu:

  * @throws \Illuminate\Contracts\Container\BindingResolutionException
     * @throws \Illuminate\Contracts\Container\CircularDependencyException
    public function build($concrete)
        // If the concrete type is actually a Closure, we will just execute it and
        // hand back the results of the functions, which allows functions to be
        // used as resolvers for more fine-tuned resolution of these objects.
        if ($concrete instanceof Closure) {
            return $concrete($this, $this->getLastParameterOverride());
        try {
            $reflector = new ReflectionClass($concrete);
        } catch (ReflectionException $e) {
            throw new BindingResolutionException("Target class [$concrete] does not exist.", 0, $e);
        // If the type is not instantiable, the developer is attempting to resolve
        // an abstract type such as an Interface or Abstract Class and there is
        // no binding registered for the abstractions so we need to bail out.
        if (! $reflector->isInstantiable()) {
            return $this->notInstantiable($concrete);
        // if (in_array($concrete, $this->buildStack)) {
        //     throw new CircularDependencyException("Circular dependency detected while resolving [{$concrete}].");
        // }
        $this->buildStack[] = $concrete;

web.php’de hata almama sebep olan route yapısı:

Route::get('/xxx/{id}/', 'xxxController@show');

Hatanın düzelmesi için eklenmesi gereken kod: App\Http\Controllers\

Düzeltmeden sonrası:

Route::get('/xxx/{id}/', 'App\Http\Controllers\xxxController@show');
Bu İçeriğe Puan Verebilirsiniz
[Toplam: 1 Ortalama: 5]

Bir cevap yazın

E-posta hesabınız yayımlanmayacak.

This site uses Akismet to reduce spam. Learn how your comment data is processed.