Fix ternary