fix: source

This commit is contained in:
Fine 2023-06-03 15:45:16 +08:00
parent b7fe7b4e4c
commit c19f9000a0

View File

@ -362,7 +362,7 @@ limitations under the License. -->
} }
const { metricConfig, metricTypes, metrics } = dashboardStore.selectedGrid; const { metricConfig, metricTypes, metrics } = dashboardStore.selectedGrid;
if (!(metrics && metrics[0] && metricTypes && metricTypes[0])) { if (!(metrics && metrics[0] && metricTypes && metricTypes[0])) {
return; return emit("update", {});
} }
const params = useQueryProcessor({ ...states, metricConfig }); const params = useQueryProcessor({ ...states, metricConfig });
if (!params) { if (!params) {
@ -384,7 +384,7 @@ limitations under the License. -->
async function queryMetricsWithExpressions() { async function queryMetricsWithExpressions() {
const { metricConfig, typesOfMQE, expressions } = dashboardStore.selectedGrid; const { metricConfig, typesOfMQE, expressions } = dashboardStore.selectedGrid;
if (!(expressions && expressions[0] && typesOfMQE && typesOfMQE[0])) { if (!(expressions && expressions[0] && typesOfMQE && typesOfMQE[0])) {
return; return emit("update", {});
} }
const params = useExpressionsQueryProcessor({ ...states, metricConfig }); const params = useExpressionsQueryProcessor({ ...states, metricConfig });