main
Ilham Wara Nugroho 2026-02-09 13:59:48 +07:00
parent b36eff23b9
commit 05ee032f1d
1 changed files with 2 additions and 2 deletions

View File

@ -18,8 +18,8 @@ class Profile
*/
public function handle(Request $request, Closure $next): Response
{
$user = Sekolah::where('npsn',auth()->user()->username)->where('ms_group_id',2)->first();
if(!@$user->profile && ($user->ms_group_id == 2)){
$user = Sekolah::where('npsn',auth()->user()->username)->first();
if(!@$user && (auth()->user()->ms_group_id == 2)){
return redirect('profile-sekolah/lengkapi/'.encode_id($user->username));
}
return $next($request);