detecting if you're logged in or not