WP_Roles::_init()protectedWP 2.1.0

Устарела с версии 4.9.0. Больше не поддерживается и может быть удалена. Используйте WP_Roles::for_site().

Sets up the object properties.

The role key is set to the current prefix for the $wpdb object with 'user_roles' appended. If the $wp_user_roles global is set, then it will be used and the role option will not be updated or used.

Метод класса: WP_Roles{}

Хуков нет.

Возвращает

null. Ничего (null).

Использование

// protected - в коде основоного (родительского) или дочернего класса
$result = $this->_init();

Список изменений

С версии 2.1.0 Введена.
Устарела с 4.9.0 Use WP_Roles::for_site()

Код WP_Roles::_init() WP 6.5.2

protected function _init() {
	_deprecated_function( __METHOD__, '4.9.0', 'WP_Roles::for_site()' );

	$this->for_site();
}