Don't use initializer syntax for instantiating client
For some reason, the property initializer syntax stopped working. An update to TypeScript? An update to Jest? Unknown, but sticking to the less fancy constructor body to do property init seems to work. Signed-off-by: Charles Lowell <cowboyd@frontside.com>
This commit is contained in:
+5
-4
@@ -72,15 +72,16 @@ function isBlank(str: string) {
|
||||
* @public
|
||||
*/
|
||||
export class ElasticSearchSearchEngine implements SearchEngine {
|
||||
private readonly elasticSearchClient: Client = this.newClient(
|
||||
options => new Client(options),
|
||||
);
|
||||
private readonly elasticSearchClient: Client;
|
||||
|
||||
constructor(
|
||||
private readonly elasticSearchClientOptions: ElasticSearchClientOptions,
|
||||
private readonly aliasPostfix: string,
|
||||
private readonly indexPrefix: string,
|
||||
private readonly logger: Logger,
|
||||
) {}
|
||||
) {
|
||||
this.elasticSearchClient = this.newClient(options => new Client(options));
|
||||
}
|
||||
|
||||
static async fromConfig({
|
||||
logger,
|
||||
|
||||
Reference in New Issue
Block a user