<?php
/**
 * ------------------------ 
 *  版权所有  www.tecmz.com
 *  商业版本请购买正版授权使用
 * ------------------------
*/ namespace Module\Member\Middleware; use Illuminate\Support\Facades\Session; use Illuminate\Support\Facades\View; use ModStart\Core\Input\Request; use ModStart\Core\Input\Response; use Module\Member\Support\MemberLoginCheck; use Module\Member\Type\MemberStatus; use Module\Member\Util\MemberUtil; class WebAuthMiddleware { public function handle($sqTc8, \Closure $k4aFB) { goto lTSF_; p7AQK: Session::put('memberUserId', $d4RRw); goto UdYfO; W4mWv: $d4RRw = intval(Session::get('memberUserId', 0)); goto fz83a; QpdS9: return $k4aFB($sqTc8); goto xiSB1; oZE2r: View::share('_memberUserId', $d4RRw); goto n6_ma; lTSF_: list($h42gY, $uNY85) = Request::getControllerAction(); goto W4mWv; r0QzX: if ($d4RRw) { goto CeZ67; mpGXy: MemberUtil::processDefault($J09PA); goto YhRWv; YhRWv: if ($J09PA) { switch ($J09PA['status']) { case MemberStatus::FORBIDDEN: $J09PA = null; break; } } goto Il8Or; CeZ67: $J09PA = MemberUtil::get($d4RRw); goto mpGXy; Il8Or: } goto xFFme; fz83a: $J09PA = null; goto r0QzX; n6_ma: if (empty($d4RRw)) { if (is_subclass_of($h42gY, MemberLoginCheck::class)) { if (property_exists($h42gY, 'memberLoginCheckIgnores') && is_array($h42gY::$memberLoginCheckIgnores) && in_array($uNY85, $h42gY::$memberLoginCheckIgnores)) { } else { return Response::send(-1, null, null, modstart_web_url('login') . '?redirect=' . urlencode(Request::currentPageUrl())); } } } goto p7AQK; xFFme: if ($d4RRw && !$J09PA) { $d4RRw = 0; Session::forget('memberUserId'); } goto oZE2r; cpekk: View::share('_memberUser', $J09PA); goto QpdS9; UdYfO: Session::flash('_memberUser', $J09PA); goto cpekk; xiSB1: } }