It makes sense to init the cmd here, but adding the group variable seems weird?
It is being populated in the if() below