Added sign in / sign out logic