bp_nouveau_activity_secondary_avatars( $action,  $activity )


Source Source

File: bp-templates/bp-nouveau/includes/activity/functions.php

function bp_nouveau_activity_secondary_avatars( $action, $activity ) {
	switch ( $activity->component ) {
		case 'groups':
		case 'friends':
			$secondary_avatar = bp_get_activity_secondary_avatar( array( 'linked' => false ) );

			// Only insert avatar if one exists.
			if ( $secondary_avatar ) {
				$link_close  = '">';
				$first_link  = strpos( $action, $link_close );
				$second_link = strpos( $action, $link_close, $first_link + strlen( $link_close ) );
				$action      = substr_replace( $action, $secondary_avatar, $second_link + 2, 0 );
			}
			break;
	}

	return $action;
}


Top ↑

Changelog Changelog

Changelog
Version Description
3.0.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.