CheckLogin을 다시 구현.

- ajax 함수에서는 사용해선 안됨.
- 이외에선 index에서만 제대로 장수삭제처리를 하므로 문제 없을 것.
This commit is contained in:
2018-04-03 03:05:26 +09:00
parent cb56620728
commit e0cbf34d43
58 changed files with 64 additions and 68 deletions
+7 -11
View File
@@ -2,18 +2,14 @@
namespace sammo;
function CheckLogin($type=0) {
//TODO: 직접해라. setReadOnly() 호출이 필요하다.
if(Session::Instance()->loginGame()->generalID){
return;
function CheckLoginWithGeneralID() {
$session = Session::requireLogin()->loginGame()->setReadOnly();
$generalID = $session->generalID;
if($generalID){
return $generalID;
}
if($type == 0) {
header('Location: ../');
}
else {
header('Location: index.php');
}
exit();
header('Locatoin:..');
die();
}