code: public static boolean isFavorite(@Nonnull User user, @Nonnull Item item) {
          FavoriteUserProperty fup = user.getProperty(FavoriteUserProperty.class);
          return fup != null && fup.isJobFavorite(item.getFullName());
      }
docs: Check if the item is favorited
  @param user to check
  @param item to check
  @return favorite state