formatting

This commit is contained in:
denisdulici
2019-11-16 17:38:48 +03:00
parent 0d53067f7b
commit a8c5aa7efd
5 changed files with 15 additions and 17 deletions

View File

@ -84,7 +84,7 @@ class Login extends Controller
}
// Check if is customer
if ($user->contact) {
if ($user->can('read-client-portal')) {
$path = session('url.intended', 'portal');
// Path must start with 'portal' prefix

View File

@ -81,7 +81,7 @@ class Users extends Controller
*/
public function edit(User $user)
{
if ($user->contact) {
if ($user->can('read-client-portal')) {
// Show only roles with customer permission
$roles = Role::all()->reject(function ($r) {
return !$r->hasPermission('read-client-portal');