code: public static String shortName(User user) {
      if (!isEmpty(user.getFirstName()))
        return user.getFirstName();
  
      if (!isEmpty(user.getLastName()))
        return user.getLastName();
  
      return user.getUserName();
    }
docs: The short name is one of the following:
  <ol>
  <li>First name</li>
  <li>Last name</li>
  <li>Username</li>
  </ol>
  The method will try to return the first valid name in the specified order.
  
  @return the short name of the user