Created
May 21, 2014 14:50
-
-
Save dsnopek/d4656514ee7c8b964cf7 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Get information about this Space or Groups roles. | |
$og_roles = array_flip(og_roles('node', $space->type, $space->nid)); | |
$og_admin_rid = $og_roles[OG_ADMINISTRATOR_ROLE]; | |
// NOTE: This presumes the user is already a member | |
og_role_grant('node', $space->nid, $account->uid, $og_admin_rid); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment