// // AppDelegate+login.m // Overseas Watch // // Created by 刘振兴 on 2023/11/28. // Copyright © 2023 BaH Cy. All rights reserved. // #import "AppDelegate+login.h" @implementation AppDelegate (login) + (void)checkLogin { int area = [UserDataHelper getLoginType]; if (area == -1) { [[DataManager shared] showSKSelectAreaViewController]; } else { [ServerManager resetServerCategory]; NSDictionary* loginData = [UserDataHelper getLastLoginInfo]; LogInModel* loginModel = [LogInModel mj_objectWithKeyValues:loginData]; if(loginData && loginModel && loginModel.uid.length > 0 && [UserDataHelper hasLogin]) { [DataManager shared].loginModel = loginModel; [[DataManager shared] showTabBarController]; } else { [DataManager shared].loginModel = nil; [[DataManager shared] showSKLoginViewController]; } } } @end