mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
ElasticSearch: Fix errorsource in newInstanceSettings (#93859)
This commit is contained in:
parent
c2799b4901
commit
76406d65cd
@ -102,11 +102,11 @@ func newInstanceSettings(httpClientProvider *httpclient.Provider) datasource.Ins
|
||||
|
||||
timeField, ok := jsonData["timeField"].(string)
|
||||
if !ok {
|
||||
return nil, errors.New("timeField cannot be cast to string")
|
||||
return nil, exp.DownstreamError(errors.New("timeField cannot be cast to string"), false)
|
||||
}
|
||||
|
||||
if timeField == "" {
|
||||
return nil, errors.New("elasticsearch time field name is required")
|
||||
return nil, exp.DownstreamError(errors.New("elasticsearch time field name is required"), false)
|
||||
}
|
||||
|
||||
logLevelField, ok := jsonData["logLevelField"].(string)
|
||||
|
Loading…
Reference in New Issue
Block a user