Set flag fix