@@ -25,7 +25,7 @@ |
||
25 | 25 | if(Auth::user()->password_expires !== null) |
26 | 26 | { |
27 | 27 | $passExp = new Carbon((Auth::user()->password_expires)); |
28 | - if(Carbon::now() > $passExp ) |
|
28 | + if(Carbon::now() > $passExp) |
|
29 | 29 | { |
30 | 30 | Log::notice('User ID-'.Auth::user()->user_id.' is being forced to change their password.'); |
31 | 31 | $request->session()->flash('change_password', 'change_password'); |
@@ -55,7 +55,7 @@ discard block |
||
55 | 55 | // Show the links for the selected user |
56 | 56 | public function showLinks($id) |
57 | 57 | { |
58 | - $user = User::find($id); |
|
58 | + $user = User::find($id); |
|
59 | 59 | |
60 | 60 | Log::debug('Route '.Route::currentRouteName().' visited by User ID-'.Auth::user()->user_id); |
61 | 61 | return view('admin.linkDetails', [ |
@@ -88,7 +88,7 @@ discard block |
||
88 | 88 | )->update(['value' => $request->passExpire]); |
89 | 89 | |
90 | 90 | // If the setting is changing from never to xx days, update all users |
91 | - if ($request->passExpire == 0) { |
|
91 | + if($request->passExpire == 0) { |
|
92 | 92 | User::whereNotNull('password_expires')->update([ |
93 | 93 | 'password_expires' => null |
94 | 94 | ]); |
@@ -101,9 +101,9 @@ discard block |
||
101 | 101 | ]); |
102 | 102 | } |
103 | 103 | |
104 | - Log::debug('Route ' . Route::currentRouteName() . ' visited by User ID-' . Auth::user()->user_id); |
|
104 | + Log::debug('Route '.Route::currentRouteName().' visited by User ID-'.Auth::user()->user_id); |
|
105 | 105 | Log::debug('Submitted Data - ', $request->toArray()); |
106 | - Log::notice('User Settings have been changed by User ID-' . Auth::user()->user_id); |
|
106 | + Log::notice('User Settings have been changed by User ID-'.Auth::user()->user_id); |
|
107 | 107 | return redirect()->back()->with('success', 'User Security Updated'); |
108 | 108 | } |
109 | 109 | |
@@ -162,7 +162,7 @@ discard block |
||
162 | 162 | 'name' => $request->name, |
163 | 163 | 'description' => $request->description, |
164 | 164 | ]); |
165 | - foreach ($request->permissions as $perm) |
|
165 | + foreach($request->permissions as $perm) |
|
166 | 166 | { |
167 | 167 | UserRolePermissions::create([ |
168 | 168 | 'role_id' => $role->role_id, |
@@ -37,8 +37,7 @@ discard block |
||
37 | 37 | $userLinks = new UserCollection( |
38 | 38 | User::withCount([ |
39 | 39 | 'FileLinks', |
40 | - 'FileLinks as expired_file_links_count' => function($query) |
|
41 | - { |
|
40 | + 'FileLinks as expired_file_links_count' => function($query) { |
|
42 | 41 | $query->where('expire', '<', Carbon::now()); |
43 | 42 | } |
44 | 43 | ]) |
@@ -88,7 +87,8 @@ discard block |
||
88 | 87 | )->update(['value' => $request->passExpire]); |
89 | 88 | |
90 | 89 | // If the setting is changing from never to xx days, update all users |
91 | - if ($request->passExpire == 0) { |
|
90 | + if ($request->passExpire == 0) |
|
91 | + { |
|
92 | 92 | User::whereNotNull('password_expires')->update([ |
93 | 93 | 'password_expires' => null |
94 | 94 | ]); |
@@ -110,8 +110,7 @@ discard block |
||
110 | 110 | public function roleSettings() |
111 | 111 | { |
112 | 112 | $this->authorize('hasAccess', 'Manage User Roles'); |
113 | - $roles = UserRoleType::with(['UserRolePermissions' => function($query) |
|
114 | - { |
|
113 | + $roles = UserRoleType::with(['UserRolePermissions' => function($query) { |
|
115 | 114 | $query->join('user_role_permission_types', 'user_role_permission_types.perm_type_id', '=', 'user_role_permissions.perm_type_id'); |
116 | 115 | }])->get(); |
117 | 116 | $perms = UserRolePermissionTypes::all(); |