mg: enable/disable only if needed
Closes #3577 (closed)
This fixes disable_all
when nothing have to be disabled.
The problem come from disable
which uses a *counter
+ a name solving. And a check if some object was found after the solving.
DAIQUIRI [2]: tomo_mock_mg.disable_all()
!!! === ValueError: No match, could not disable any counter with patterns: === !!! ( for more details type cmd 'last_error' )
DAIQUIRI [2]: tomo_mock_mg.disable()
!!! === ValueError: No match, could not disable any counter with patterns: === !!! ( for more details type cmd 'last_error' )
Now if there is no input to disable
the function early returns.