Opened 6 years ago
Closed 4 years ago
#8076 closed defect (bug) (fixed)
Bug in user count -> E.g. on Members Page
Reported by: | lordofdoom | Owned by: | |
---|---|---|---|
Milestone: | Awaiting Review | Priority: | normal |
Severity: | normal | Version: | |
Component: | Templates | Keywords: | |
Cc: |
Description
There is a bug in buddypress/bp-templates/bp-nouveau/includes/template-tags.php
$nav_item->count return a string, but if a site have more than 1k users this string will be 1,000 -> So the integer will be 1
Line 1247 need to get changed from:
<?php if ( 'directory' === $bp_nouveau->displayed_nav ) { $count = (int) $nav_item->count;
to e.g.:
<?php if ( 'directory' === $bp_nouveau->displayed_nav ) { $count = intval(str_replace(",","",$nav_item->count));
Thank you :-)
Change History (3)
Note: See
TracTickets for help on using
tickets.
Another option (better) is not to return a string at all for a count function :-)