Switched to an if else statement.