function __construct() { if (!class_exists('BuddyPress')) { return; } if (!bp_is_active('friend')) { return; } }