WP_Roles::reinit() public WP 3.5.0
Устарела с версии 4.7.0. Больше не поддерживается и может быть удалена. Используйте
WP_Roles::for_site()
.╳Reinitialize the object
Recreates the role objects. This is typically called only by switch_to_blog() after switching wpdb to a new site ID.
{} Это метод класса: WP_Roles{}
Хуков нет.
Возвращает
null
. Ничего.
Использование
global $wp_roles; $wp_roles->reinit();
Список изменений
С версии 3.5.0 | Введена. |
Устарела с 4.7.0 | Use WP_Roles::for_site() |
Код WP_Roles::reinit() WP Roles::reinit WP 5.7.1
public function reinit() {
_deprecated_function( __METHOD__, '4.7.0', 'WP_Roles::for_site()' );
$this->for_site();
}