fixed double page render when not logged in