diff --git a/plugins/modules/apache2_module.py b/plugins/modules/apache2_module.py index 99db968670..7de2f8d18e 100644 --- a/plugins/modules/apache2_module.py +++ b/plugins/modules/apache2_module.py @@ -258,7 +258,7 @@ def main(): ) name = module.params['name'] - if name == 'cgi' and _run_threaded(module): + if name == 'cgi' and module.params['state'] == 'present' and _run_threaded(module): module.fail_json(msg="Your MPM seems to be threaded. No automatic actions on module cgi possible.") if not module.params['identifier']: