Fix cookie setting.