bbp_maybe_append_pending_upgrade_count( string $string = '', string $type = '' )
Maybe append an upgrade count to a string
Description Description
Parameters Parameters
- $string
- 
					(Optional) Text to append count to Default value: '' 
- $type
- 
					(Optional) Type of pending upgrades (upgrade|repair|empty) Default value: '' 
Return Return
(string)
Source Source
File: includes/core/update.php
function bbp_maybe_append_pending_upgrade_count( $string = '', $type = '' ) {
	// Look for an upgrade count
	$count = bbp_get_pending_upgrade_count( $type );
	// Append the count to the string
	if ( ! empty( $count ) ) {
		$suffix = ' <span class="awaiting-mod count-' . absint( $count ) . '"><span class="pending-count">' . bbp_number_format( $count ) . '</span></span>';
		$string = "{$string}{$suffix}";
	}
	// Return the string, maybe with a count
	return $string;
}
			Changelog Changelog
| Version | Description | 
|---|---|
| 2.6.0 | Introduced. |