Remove unnecessary if-statement