In 6.x-2.4 and 6.x-2.3.

To see the problem:
- Install commons
- Go to Home > Administer > Organic groups > Subgroups configuration
(/admin/og/subgroups)
- Unselect "Group" in "Enable subgroups for group types"
- Create a regular user account
- Log into the user account
- Join the pre-created "Our Community" group
- Create a test group
- Create a blog post
- Error message "You must join a group before posting" is displayed

This message is not displayed if the user is a member of single group. Must be a member of at least 2 groups.
Administrators can still create content but it is not placed in a group.

From what I've been able to determine, og_subgroups is removing the value for $form[og_nodeapi][visible][og_groups][#options] in hook_form_alter, with this value missing the og_features module assumes the user doesn't belong to any groups and kicks out the error "You must join a group before posting".
Single group edge case: When the user is a member of a single group the format of $form['og_nodeapi'] is slightly different, so the problem seems to be bypassed.

In our case we only have one group type, so we've been able to work around this issue by leaving subgroups enabled and disabling "edit groups hierarchy". The solution wouldn't work if there were two types of group nodes, one with sub-groups enabled, and the other with sub-groups disabled.

Comments

japerry’s picture

Issue summary: View changes
Status: Active » Closed (won't fix)

Marking as won't fixed as this is no longer relevant for newest versions of commons, and the 6.x-2.x is only getting security fixes. You can also visit #2142923: Upgrading From Drupal 1.5 to 2.x or 3.x for the update status of legacy commons installs and more information on upgrading to the latest version of Commons.