Explorar el Código

Explore: Fixes error when switching from prometheus to loki data sources (#18599)

Closes #18594
Closes #18596
kay delaney hace 6 años
padre
commit
bf82e6cded
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      public/app/features/explore/QueryField.tsx

+ 1 - 1
public/app/features/explore/QueryField.tsx

@@ -115,7 +115,7 @@ export class QueryField extends React.PureComponent<QueryFieldProps, QueryFieldS
     if (initialQuery !== prevProps.initialQuery) {
       // and we have a version that differs
       if (initialQuery !== Plain.serialize(value)) {
-        this.setState({ value: makeValue(initialQuery, syntax) });
+        this.setState({ value: makeValue(initialQuery || '', syntax) });
       }
     }