several fixes regarding new cookie system