fix cookie behind login and logout