mirror of
https://github.com/grafana/grafana.git
synced 2025-09-21 22:07:37 +08:00
TemplateSrv: exposing a function to detect if a target contains a template (#45214)
* exposing a function to check if a target contains variables. * fixed tests. * renamed function * updated betterer result.
This commit is contained in:
@ -213,6 +213,6 @@ export class PostgresDatasource extends DataSourceWithBackend<PostgresQuery, Pos
|
||||
|
||||
rawSql = rawSql.replace('$__', '');
|
||||
|
||||
return this.templateSrv.variableExists(rawSql);
|
||||
return this.templateSrv.containsTemplate(rawSql);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user