Added method to check login status