Skip to:
Content

BuddyPress.org

Changeset 8578


Ignore:
Timestamp:
07/09/2014 08:30:58 PM (10 years ago)
Author:
johnjamesjacoby
Message:

Use $r['max'] instead of previously exploded $max when attempting to set notification_count. Fixes inability to limit the maximum number of visible notifications.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-notifications/bp-notifications-template.php

    r8142 r8578  
    308308
    309309        } else {
    310             if ( ! empty( $max ) ) {
    311                 if ( $max >= count( $this->notifications ) ) {
     310            if ( ! empty( $r['max'] ) ) {
     311                if ( $r['max'] >= count( $this->notifications ) ) {
    312312                    $this->notification_count = count( $this->notifications );
    313313                } else {
    314                     $this->notification_count = (int) $max;
     314                    $this->notification_count = (int) $r['max'];
    315315                }
    316316            } else {
Note: See TracChangeset for help on using the changeset viewer.