please use `if...else` instead of ternary operator