Refactor getLoggedInCookie method.