Was trying to add a custom link to the group admin block using hook_og_ui_get_group_admin(). The link is used to add a new user to Drupal, and add them to "this" group using entityreference_prepopulate (and og_register). I also wanted to add a destination back to the group page.
In og_ui.admin.inc, og_ui_group_admin_overview() sets $item['localized_options] to an empty array:
foreach ($items as &$item) {
// Re-format the URL.
$item['href'] = "group/$entity_type/$etid/" . $item['href'];
// Imitate the menu_get_item() content, so we can pass it to
// theme_admin_block_content(), so we add the localized_options key.
$item['localized_options'] = array();
}
The comment indicates the need to add a localized_options key, but if you happened to pass your own localized_options to this function, you are out of luck.
To keep my project moving, I quickly hacked the module with a simple conditional:
if(empty($item['localized_options'])) {
$item['localized_options'] = array();
}
This seems to work fine. Any reason why it shouldn't be included in the module? Happy to provide a patch is this is useful and doesn't break anything else.