mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Panels: Fixes crashing issue when migrating angular panels (#58232)
This commit is contained in:
@@ -66,10 +66,9 @@ export function updateDuplicateLibraryPanels(
|
||||
panel.configRev++;
|
||||
|
||||
if (pluginChanged) {
|
||||
const cleanUpKey = panel.key;
|
||||
panel.generateNewKey();
|
||||
|
||||
dispatch(panelModelAndPluginReady({ key: panel.key, plugin: panel.plugin!, cleanUpKey }));
|
||||
dispatch(panelModelAndPluginReady({ key: panel.key, plugin: panel.plugin! }));
|
||||
}
|
||||
|
||||
// Resend last query result on source panel query runner
|
||||
@@ -129,10 +128,9 @@ export function exitPanelEditor(): ThunkResult<void> {
|
||||
if (panelTypeChanged) {
|
||||
// Loaded plugin is not included in the persisted properties so is not handled by restoreModel
|
||||
sourcePanel.plugin = panel.plugin;
|
||||
const cleanUpKey = sourcePanel.key;
|
||||
sourcePanel.generateNewKey();
|
||||
|
||||
await dispatch(panelModelAndPluginReady({ key: sourcePanel.key, plugin: panel.plugin!, cleanUpKey }));
|
||||
await dispatch(panelModelAndPluginReady({ key: sourcePanel.key, plugin: panel.plugin! }));
|
||||
}
|
||||
|
||||
// Resend last query result on source panel query runner
|
||||
|
||||
Reference in New Issue
Block a user