Merge branch 'stable-2.16' into stable-3.0

* stable-2.16:
  ListUsersCommand: Fix NullPointerException when username is not set

Change-Id: I2c430f529759864cd50dd95d01399172b262e595
diff --git a/src/main/java/com/googlesource/gerrit/plugins/adminconsole/ListUsersCommand.java b/src/main/java/com/googlesource/gerrit/plugins/adminconsole/ListUsersCommand.java
index 78ac5ab..2c7062b 100644
--- a/src/main/java/com/googlesource/gerrit/plugins/adminconsole/ListUsersCommand.java
+++ b/src/main/java/com/googlesource/gerrit/plugins/adminconsole/ListUsersCommand.java
@@ -71,7 +71,7 @@
               .append(account.getId().toString())
               .append(" |")
               .append(
-                  Strings.isNullOrEmpty(accountState.getUserName().get())
+                  accountState.getUserName().isPresent()
                       ? ""
                       : " " + accountState.getUserName().get())
               .append(" |")