Avoid redundant ternary operator