fix display of categories and only print relogin message once per login