@since: bbPress (r4363)
Description
_bbp_reinit_dynamic_roles()

This is necessary because in a few places (noted below) WordPress initializes a blog’s roles directly from the database option. When this happens, the $wp_roles global gets flushed, causing a user to magically lose any dynamically assigned roles or capabilities when $current_user in refreshed.

Source: bp-forums/core/capabilities.php:359

bbp_filter_user_roles_option()

Helper function to add filter to option_wp_user_roles

Source: bp-forums/core/capabilities.php:328