Fixes #18045 - Puppet classes show up choosing only env.
After #3551 was merged, the hosts controller requires both environmentand hostgroup to be set in order to display puppetclasses.
It shouldn't be required to have both, so we should check what'savailable and use it. If it's only the hostgroup or the environment, itshould work.
Fixes #18045 - Puppet classes show up choosing only env.
After #3551 was merged, the hosts controller requires both environment
and hostgroup to be set in order to display puppetclasses.
It shouldn't be required to have both, so we should check what's
available and use it. If it's only the hostgroup or the environment, it
should work.