update cookie flag