make roles final

This commit is contained in:
javanna 2016-03-24 15:20:50 +01:00 committed by Luca Cavanna
parent 2ea694b4bc
commit 06fd61fb00
1 changed files with 2 additions and 2 deletions

View File

@ -281,8 +281,8 @@ public class RestNodesAction extends AbstractCatAction {
table.addCell(!hasLoadAverage || osStats.getCpu().getLoadAverage()[2] == -1 ? null : String.format(Locale.ROOT, "%.2f", osStats.getCpu().getLoadAverage()[2]));
table.addCell(jvmStats == null ? null : jvmStats.getUptime());
String roles;
if (node.getRoles().size() == 0) {
final String roles;
if (node.getRoles().isEmpty()) {
roles = "-";
} else {
roles = node.getRoles().stream().map(DiscoveryNode.Role::getAbbreviation).collect(Collectors.joining());