mirror of
https://github.com/elastic/kibana.git
synced 2025-04-23 17:28:26 -04:00
[ui] do not assume es plugin is always there
This commit is contained in:
parent
7ad237cce1
commit
5ac383d476
1 changed files with 4 additions and 2 deletions
|
@ -93,11 +93,13 @@ export default async (kbnServer, server, config) => {
|
|||
}
|
||||
|
||||
async function renderApp(app) {
|
||||
const isElasticsearchPluginRed = server.plugins.elasticsearch.status.state === 'red';
|
||||
const payload = await getPayload.call(this, app);
|
||||
if (!isElasticsearchPluginRed) {
|
||||
|
||||
const esStatus = kbnServer.status.getForPluginId('elasticsearch');
|
||||
if (esStatus && esStatus.state !== 'red') {
|
||||
payload.uiSettings.user = await server.uiSettings().getUserProvided();
|
||||
}
|
||||
|
||||
return viewAppWithPayload.call(this, app, payload);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue