Added a check for the presence of another input flag