Skip to:
Content
Pages
Categories
Search
Top
Bottom

Bugfix: Incorrect menu_order if topic has over 1,000 replies

  • @drpepper75

    Participant

    A really small bug caused incorrect menu_order of new replies if a topic reached over 1000 replies.

    The solve this the file includes/replies/functions.php has to be changed.
    Line 264: ‘menu_order’     => bbp_get_topic_reply_count( $topic_id, false ) + 1;

    Should be: ‘menu_order’     => bbp_get_topic_reply_count( $topic_id, true ) + 1;

    If not true a comma will be added for the thousands. Which results in only the number before the comma will be used.

    I will be glad to see this will be changed in the next version of bbPress.

Viewing 3 replies - 1 through 3 (of 3 total)
  • @superbio

    Participant

    So many thanks, Remi. That really helped a lot!

    @slothlovechunk

    Participant

    Thanks. I just ran into this problem as well and this fixed it. I will try and create a trac ticket for this in a bit.

    @phagento

    Participant

    Good spot! I’m using a very old bbPress version in a project and can reproduce this error. Upgrade is not an option this time. Changing the second param to true fixes the error I’m getting.

Viewing 3 replies - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.
Skip to toolbar