code: public static String resolve(User u, String avatarSize) {
          String avatar = resolveOrNull(u, avatarSize);
          return avatar != null ? avatar : Jenkins.getInstance().getRootUrl() + Functions.getResourcePath() + "/images/" + avatarSize + "/user.png";
      }
docs: Resolve an avatar image URL string for the user.
  Note that this method must be called from an HTTP request to be reliable; else use {@link #resolveOrNull}.
  @param u user
  @param avatarSize the preferred image size, "[width]x[height]"
  @return a URL string for a user Avatar image.