adjusts header and logout behavior