title: isAuthorized redirect URL cakephp
body: <p>When <code>isAuthorized = false</code> the user is redirected to '/' is there a way to change this. I want to redirect to the user dashboard (/users/dashboard) with a flash message saying 'Access prohibited' or something like that.</p>
  
  <p>Cheers!</p>
  
  <pre><code>public function isAuthorized($user) {
      if (isset($user['role']) &amp;&amp; $user['role'] === 'admin') {
          return true; //Admin can access every action
      }
      return false; // The rest don't
  }
  </code></pre>