# Showing home page instead of login if already logged in without animation

**URL:** <https://forum.ionicframework.com/t/showing-home-page-instead-of-login-if-already-logged-in-without-animation/15549>\
**Category:** ionic-v1\
**Created:** [January 12, 2015, 9:04pm UTC](https://forum.ionicframework.com/t/showing-home-page-instead-of-login-if-already-logged-in-without-animation/15549 "2015-01-12T21:04:55Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![devqon1](https://avatars.discourse-cdn.com/v4/letter/d/f17d59/32.png) [@devqon1](https://forum.ionicframework.com/u/devqon1)\
**Post date:** [January 13, 2015, 8:01am UTC](https://forum.ionicframework.com/t/showing-home-page-instead-of-login-if-already-logged-in-without-animation/15549/4 "2015-01-13T08:01:17Z")

</div>

In my app I have it the other way around: set a default home page, when starting up check if authorized, otherwise show login.

In my `$ionicPlatformReady` function:

```
// Platform ready
$ionicPlatform.ready(function () {

   $log.log("Application initialized", $filter('date')(new Date(), 'short'));

   // Show login page if not authenticated
   if (!AuthService.isAuthenticated() && !appConfig.IS_DEBUG_MODE)
       AuthService.tryAuthorize();
});
```

---

_[View the full topic](https://forum.ionicframework.com/t/showing-home-page-instead-of-login-if-already-logged-in-without-animation/15549)._
