protected function SearchApiElasticsearchService::setPath in Search API Elasticsearch 7.2
Helper function. Return the path in the correct format.
Parameters
string $path:
Return value
string
1 call to SearchApiElasticsearchService::setPath()
- SearchApiElasticsearchService::configurationFormValidate in includes/
SearchApiElasticsearchService.inc - @inheritdoc
File
- includes/
SearchApiElasticsearchService.inc, line 474 - Provides Elasticsearch service for Search API.
Class
- SearchApiElasticsearchService
- @file Provides Elasticsearch service for Search API.
Code
protected function setPath($path) {
if (isset($path) && !empty($path)) {
$trimmed_path = trim($path, '/');
$path = $trimmed_path . '/';
}
return $path;
}