project_flag and project_name logic fixed