Fix accidental removal of if() in commit 38905