if ($exception instanceof AuthorizationException){
return redirect(route('profile.index'));
}
above return parent::render($request, $exception); line
in the render method , but its not effective
can you guide me through whats wrong?
update:
I removed the if condition and it works but of course it return all kinds of error to profile , maybe the Exception that Gate throws is not Authorization ?