diff --git a/lib/splashPage.dart b/lib/splashPage.dart index a40eb0c5..aaffcbbd 100644 --- a/lib/splashPage.dart +++ b/lib/splashPage.dart @@ -30,28 +30,17 @@ class _SplashScreenState extends State { Timer( Duration(seconds: 1, milliseconds: 500), () { - getUserData().then((value) { - loadPrivilege().then((value) { - Navigator.of(context).pushReplacement( - MaterialPageRoute( - builder: (BuildContext context) => LandingPage(), - ), - ); - }); + loadPrivilege().then((value) { + Navigator.of(context).pushReplacement( + MaterialPageRoute( + builder: (BuildContext context) => LandingPage(), + ), + ); }); }, ); } - Future getUserData() async { - var data = await sharedPref.getObject(USER_PROFILE); - if (data != null) { - AuthenticatedUser userData = AuthenticatedUser.fromJson(data); - Provider.of(context, listen: false).isLogin = true; - authenticatedUserObject.isLogin = true; - authenticatedUserObject.user = userData; - } - } /// load the Privilege from service Future loadPrivilege() async {