Grouped both the IFs to remove redundat statements

There wasn't any need to have two different if statements. So cleaned it up by adding OR.