This reverts commit d37b283c. There was a simple logic bug in the else path. Tests codegen is different with the fix.