Refactor simple conditional