No need for ternary operation in canvas._maybe_group