Revert "Fix logic error"

This reverts commit acb7bb5481fafe9bc2220a8fd2661e358eec590d.