Before considering patches, you should try 'Restricted Access'. Restricted access may not have been turned on for your site, but it's easy for a site administrator to do without making any modifications to code. It's under Site administration > Advanced features > Enable restricted access. With restricted access on, go to the settings page for an activity and you will find a new settings section called "Restrict access". Open that and click "Add restriction", then click "Group" and set the group who gets to see the activity. You can add other restrictions while you are there, including adding more than one group. This works in 2.8, though later versions have additional logic that lets you set various clever kinds of combinations. I don't think you need the patch.
by Kevin Wiliarty.