Skip to content

Commit

Permalink
change route name for login redirection
Browse files Browse the repository at this point in the history
  • Loading branch information
maximebeaudoin committed Jul 12, 2013
1 parent 78b0acd commit ba60067
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions src/Firalabs/Firadmin/Controllers/UserController.php
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ public function index()
{
//Check permission
if(Permissions::isAllowed(Auth::user(), 'user', 'read') !== true){
return Redirect::route('login')
return Redirect::route('get admin/login')
->with('reason', Lang::get('firadmin::admin.messages.insufficient-permission') . '<br>')
->with('error', 1);
}
Expand Down Expand Up @@ -87,7 +87,7 @@ public function create()
{
//Check permission
if(Permissions::isAllowed(Auth::user(), 'user', 'create') !== true){
return Redirect::route('login')
return Redirect::route('get admin/login')
->with('reason', Lang::get('firadmin::admin.messages.insufficient-permission') . '<br>')
->with('error', 1);
}
Expand All @@ -110,7 +110,7 @@ public function store()
{
//Check permission
if(Permissions::isAllowed(Auth::user(), 'user', 'create') !== true){
return Redirect::route('login')
return Redirect::route('get admin/login')
->with('reason', Lang::get('firadmin::admin.messages.insufficient-permission') . '<br>')
->with('error', 1);
}
Expand Down Expand Up @@ -174,7 +174,7 @@ public function show($id)
{
//Check permission
if(Permissions::isAllowed(Auth::user(), 'user', 'read') !== true){
return Redirect::route('login')
return Redirect::route('get admin/login')
->with('reason', Lang::get('firadmin::admin.messages.insufficient-permission') . '<br>')
->with('error', 1);
}
Expand Down Expand Up @@ -226,7 +226,7 @@ public function edit($id)
{
//Check permission
if(Permissions::isAllowed(Auth::user(), 'user', 'update') !== true){
return Redirect::route('login')
return Redirect::route('get admin/login')
->with('reason', Lang::get('firadmin::admin.messages.insufficient-permission') . '<br>')
->with('error', 1);
}
Expand Down Expand Up @@ -277,7 +277,7 @@ public function update($id)
{
//Check permission
if(Permissions::isAllowed(Auth::user(), 'user', 'update') !== true){
return Redirect::route('login')
return Redirect::route('get admin/login')
->with('reason', Lang::get('firadmin::admin.messages.insufficient-permission') . '<br>')
->with('error', 1);
}
Expand Down Expand Up @@ -396,7 +396,7 @@ public function changePassword($id)
{
//Check permission
if(Permissions::isAllowed(Auth::user(), 'user', 'update') !== true){
return Redirect::route('login')
return Redirect::route('get admin/login')
->with('reason', Lang::get('firadmin::admin.messages.insufficient-permission') . '<br>')
->with('error', 1);
}
Expand Down Expand Up @@ -478,7 +478,7 @@ public function destroy($id)
{
//Check permission
if(Permissions::isAllowed(Auth::user(), 'user', 'delete') !== true){
return Redirect::route('login')
return Redirect::route('get admin/login')
->with('reason', Lang::get('firadmin::admin.messages.insufficient-permission') . '<br>')
->with('error', 1);
}
Expand Down

0 comments on commit ba60067

Please sign in to comment.