Fix for login/logout pages #583 & #573