Automattic\WooCommerce\Database\Migrations
TableMigrator::add_error()
Add an error message to the errors list unless it's there already.
Метод класса: TableMigrator{}
Хуков нет.
Возвращает
null
. Ничего.
Использование
// protected - в коде основоного (родительского) или дочернего класса $result = $this->add_error( $error ): void;
- $error(строка) (обязательный)
- The error message to add.
Код TableMigrator::add_error() TableMigrator::add error WC 7.5.1
protected function add_error( string $error ): void { if ( ! in_array( $error, $this->errors, true ) ) { $this->errors[] = $error; } }