looks like the ternary ruined everything