Fix irm enabled organization sync setting (#5174)
Check the right settings when enabling/disabling the irm plugin.
This commit is contained in:
parent
0672d06112
commit
10b532c688
2 changed files with 5 additions and 1 deletions
|
|
@ -71,7 +71,7 @@ def _sync_organization(organization: Organization) -> None:
|
|||
|
||||
# get IRM plugin settings
|
||||
is_grafana_irm_enabled = False
|
||||
grafana_irm_plugin_settings, _ = grafana_api_client.get_grafana_labels_plugin_settings()
|
||||
grafana_irm_plugin_settings, _ = grafana_api_client.get_grafana_irm_plugin_settings()
|
||||
if grafana_irm_plugin_settings is not None:
|
||||
is_grafana_irm_enabled = grafana_irm_plugin_settings["enabled"]
|
||||
|
||||
|
|
|
|||
|
|
@ -68,6 +68,10 @@ def patched_grafana_api_client(organization, is_rbac_enabled_for_organization=(F
|
|||
],
|
||||
None,
|
||||
)
|
||||
mock_client_instance.get_grafana_irm_plugin_settings.return_value = (
|
||||
{"enabled": False, "jsonData": {}},
|
||||
None,
|
||||
)
|
||||
mock_client_instance.get_grafana_incident_plugin_settings.return_value = (
|
||||
{"enabled": True, "jsonData": {GRAFANA_INCIDENT_PLUGIN_BACKEND_URL_KEY: MOCK_GRAFANA_INCIDENT_BACKEND_URL}},
|
||||
None,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue