title: ReflectionException in Container.php line 776: Class APPPATH\Http\Controllers\DashboardController does not exist
body: <p>I know that this error exist in many posts but I tried everything without any solution. After I changed the value model in the auth.php file, to the correct path of the user model, my controllers are not working. All of the controllers throwing the following issue but only the Auth controller is working fine. The error message that I'm getting is: </p>
  
  <blockquote>
    <p>ReflectionException in Container.php line 776: Class
    APPPATH\Http\Controllers\DashboardController does not exist</p>
  </blockquote>
  
  <p>I made composer dump-autoload but still the same. My controller is inside App\Http\Controllers\Administrator\Dashboard\DashboardController.php</p>
  
  <pre><code>namespace APPPATH\Http\Controllers;
  
      class DashboardController extends Controller {}
  </code></pre>
  
  <p>and inside my route i have this</p>
  
  <pre><code>get('/', array('as' =&gt; 'administrator.dashboard', 'uses' =&gt; 'DashboardController@index'));
  
  get('/dashboard', array('as' =&gt; 'administrator.dashboard', 'uses' =&gt; 'DashboardController@index'));
  
  get('/dashboard/index', array('as' =&gt; 'administrator.dashboard', 'uses' =&gt; 'DashboardController@index'));
  </code></pre>
  
  <p>Here is the composer of laravel 5</p>
  
  <p>"autoload": {
      "classmap": [
          "database"
      ],
      "psr-4": {
          "APPPATH\": "app/"
      }
  },</p>
  
  <p>Does anyone knows why is not working? Thank you</p>
  
  <p>The error message</p>
  
  <blockquote>
    <p>ReflectionException in Container.php line 776:</p>
    
    <p>Class APPPATH\Http\Controllers\DashboardController does not exist in
    Container.php line 776</p>
    
    <p>at
    ReflectionClass->__construct('APPPATH\Http\Controllers\DashboardController')
    in Container.php line 776</p>
    
    <p>at Container->build('APPPATH\Http\Controllers\DashboardController',
    array()) in Container.php line 656</p>
    
    <p>at Container->make('APPPATH\Http\Controllers\DashboardController',
    array()) in Application.php line 620</p>
    
    <p>at Application->make('APPPATH\Http\Controllers\DashboardController')
    in ControllerDispatcher.php line 83</p>
    
    <p>at
    ControllerDispatcher->makeController('APPPATH\Http\Controllers\DashboardController')
    in ControllerDispatcher.php line 54</p>
    
    <p>at ControllerDispatcher->dispatch(object(Route), object(Request),
    'APPPATH\Http\Controllers\DashboardController', 'index') in Route.php
    line 198</p>
    
    <p>at Route->runWithCustomDispatcher(object(Request)) in Route.php line
    131</p>
    
    <p>at Route->run(object(Request)) in Router.php line 691</p>
    
    <p>at Router->Illuminate\Routing{closure}(object(Request)) at
    call_user_func(object(Closure), object(Request)) in Pipeline.php line
    141</p>
    
    <p>at Pipeline->Illuminate\Pipeline{closure}(object(Request)) at
    call_user_func(object(Closure), object(Request)) in Pipeline.php line
    101</p>
    
    <p>at Pipeline->then(object(Closure)) in Router.php line 693</p>
    
    <p>at Router->runRouteWithinStack(object(Route), object(Request)) in
    Router.php line 660</p>
    
    <p>at Router->dispatchToRoute(object(Request)) in Router.php line 618</p>
    
    <p>at Router->dispatch(object(Request)) in Kernel.php line 214</p>
    
    <p>at Kernel->Illuminate\Foundation\Http{closure}(object(Request)) at
    call_user_func(object(Closure), object(Request)) in Pipeline.php line
    141</p>
    
    <p>at Pipeline->Illuminate\Pipeline{closure}(object(Request)) in
    VerifyCsrfToken.php line 43</p>
    
    <p>at VerifyCsrfToken->handle(object(Request), object(Closure)) in
    VerifyCsrfToken.php line 17</p>
    
    <p>at VerifyCsrfToken->handle(object(Request), object(Closure)) in
    Pipeline.php line 125</p>
    
    <p>at Pipeline->Illuminate\Pipeline{closure}(object(Request)) in
    ShareErrorsFromSession.php line 55</p>
    
    <p>at ShareErrorsFromSession->handle(object(Request), object(Closure)) in
    Pipeline.php line 125</p>
    
    <p>at Pipeline->Illuminate\Pipeline{closure}(object(Request)) in
    StartSession.php line 61</p>
    
    <p>at StartSession->handle(object(Request), object(Closure)) in
    Pipeline.php line 125</p>
    
    <p>at Pipeline->Illuminate\Pipeline{closure}(object(Request)) in
    AddQueuedCookiesToResponse.php line 36</p>
    
    <p>at AddQueuedCookiesToResponse->handle(object(Request),
    object(Closure)) in Pipeline.php line 125</p>
    
    <p>at Pipeline->Illuminate\Pipeline{closure}(object(Request)) in
    EncryptCookies.php line 40</p>
    
    <p>at EncryptCookies->handle(object(Request), object(Closure)) in
    Pipeline.php line 125</p>
    
    <p>at Pipeline->Illuminate\Pipeline{closure}(object(Request)) in
    CheckForMaintenanceMode.php line 42</p>
    
    <p>at CheckForMaintenanceMode->handle(object(Request), object(Closure))
    in Pipeline.php line 125</p>
    
    <p>at Pipeline->Illuminate\Pipeline{closure}(object(Request)) at
    call_user_func(object(Closure), object(Request)) in Pipeline.php line
    101</p>
    
    <p>at Pipeline->then(object(Closure)) in Kernel.php line 115</p>
    
    <p>at Kernel->sendRequestThroughRouter(object(Request)) in Kernel.php
    line 84</p>
    
    <p>at Kernel->handle(object(Request)) in index.php line 53</p>
  </blockquote>