substitute flags