Skip to content

Commit

Permalink
Extracting conditional message into its own constant for better reada…
Browse files Browse the repository at this point in the history
…bility

Former-commit-id: 6222729
  • Loading branch information
ycombinator committed Jun 15, 2016
1 parent beec1c4 commit badd469
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/ui/settings/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,8 @@ export default function setupSettings(kbnServer, server, config) {

function copyStatus() {
const { state } = esStatus;
status[state](state === 'green' ? 'Ready' : `Elasticsearch plugin is ${state}`);
const statusMessage = state === 'green' ? 'Ready' : `Elasticsearch plugin is ${state}`;
status[state](statusMessage);
}
}
}
Expand Down

0 comments on commit badd469

Please sign in to comment.