Revert "Revert "Unnecessary condition""

This reverts commit 98ad2c8b9b464973baca68c57825a82adc340bf9.