Disable all hooks for an extension. Args: extension_id: Extension ID
(self, extension_id: str)
| 3488 | self.save_project_config(config) |
| 3489 | |
| 3490 | def disable_hooks(self, extension_id: str): |
| 3491 | """Disable all hooks for an extension. |
| 3492 | |
| 3493 | Args: |
| 3494 | extension_id: Extension ID |
| 3495 | """ |
| 3496 | config = self.get_project_config() |
| 3497 | |
| 3498 | if "hooks" not in config: |
| 3499 | return |
| 3500 | |
| 3501 | # Disable all hooks for this extension |
| 3502 | for hook_name in config["hooks"]: |
| 3503 | for hook in config["hooks"][hook_name]: |
| 3504 | if hook.get("extension") == extension_id: |
| 3505 | hook["enabled"] = False |
| 3506 | |
| 3507 | self.save_project_config(config) |
nothing calls this directly
no test coverage detected