Yoast\WP\SEO\Abilities\User_Interface\Abilities
Abstract_Set_Feature_Status_Ability::can_manage_seo
Checks whether the current user can manage Yoast SEO.
Gates the ability behind the same capability that gates the settings page where the feature is toggled.
Метод класса: Abstract_Set_Feature_Status_Ability{}
Хуков нет.
Возвращает
bool. Whether the current user can manage Yoast SEO.
Использование
$Abstract_Set_Feature_Status_Ability = new Abstract_Set_Feature_Status_Ability(); $Abstract_Set_Feature_Status_Ability->can_manage_seo(): bool;
Код Abstract_Set_Feature_Status_Ability::can_manage_seo() Abstract Set Feature Status Ability::can manage seo Yoast 28.8
public function can_manage_seo(): bool {
return $this->capability_helper->current_user_can( 'wpseo_manage_options' );
}