As it is, it would be one monster ternary. But if we move the shared logic outside of the conditional, a ternary would work quite nicely. Good suggestion, I'll refactor it.