expand ternaries to full if else