Yoast\WP\SEO\Task_List\Domain\Exceptions
Incorrect_Child_Task_Usage_Exception::__construct
Constructor of the exception.
Метод класса: Incorrect_Child_Task_Usage_Exception{}
Хуков нет.
Возвращает
null. Ничего (null).
Использование
$Incorrect_Child_Task_Usage_Exception = new Incorrect_Child_Task_Usage_Exception(); $Incorrect_Child_Task_Usage_Exception->__construct( $task_identifier );
- $task_identifier(строка|null)
- The identifier of the task that caused the exception.
По умолчанию:null
Код Incorrect_Child_Task_Usage_Exception::__construct() Incorrect Child Task Usage Exception:: construct Yoast 28.9
public function __construct( $task_identifier = null ) {
$message = 'Used child task incorrectly. Child tasks should not be added to the Tasks Collector directly, as they are meant to be used within the context of their parent task.';
if ( $task_identifier !== null ) {
$message .= ' Offending task: ' . $task_identifier;
}
parent::__construct( $message, 400 );
}