Uploaded image for project: 'XWiki Platform'
  1. XWiki Platform
  2. XWIKI-17537

getRatings start and count argument not taken into account in SeparatePageRatingsManager

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Major
    • 11.10.6, 12.6
    • 6.4-milestone-3
    • Ratings
    • None
    • Unit
    • Unknown
    • N/A
    • N/A

    Description

      RatingsManager provide the an API getRatings to retrieve ratings with the following signature:

      /**
           * Gets a list of ratings
           * 
           * @param documentRef the document to which the ratings belong to
           * @param start the offset from where to fetch the ratings
           * @param count how many ratings to fetch
           * @param asc sort the results in ascending order or not
           * @return a list of Rating objects
           * @throws RatingsException when an error occurs while fetching the list of ratings
           */
          List<Rating> getRatings(DocumentReference documentRef, int start, int count, boolean asc) throws RatingsException;
      

      apparently the start and count argument are never (and have never been) taken into account in the SeparatePageRatingsManager: it means it always send back all the ratings.

      Attachments

        Activity

          People

            surli Simon Urli
            surli Simon Urli
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: