utsushiiro 6 лет назад
Родитель
Сommit
eab62073c7
1 измененных файлов с 2 добавлено и 2 удалено
  1. 2 2
      src/server/service/search-delegator/elasticsearch.js

+ 2 - 2
src/server/service/search-delegator/elasticsearch.js

@@ -91,8 +91,8 @@ class ElasticsearchDelegator {
       host = `${url.protocol}//${url.host}`;
       indexName = url.pathname.substring(1); // omit heading slash
 
-      if (url.auth != null) {
-        httpAuth = url.auth;
+      if (url.username != null && url.password != null) {
+        httpAuth = `${url.username}:${url.password}`;
       }
     }