WP_CLI
Runner::set_alias()
Метод класса: Runner{}
Хуков нет.
Возвращает
null
. Ничего (null).
Использование
// private - только в коде основоного (родительского) класса $result = $this->set_alias( $alias );
- $alias (обязательный)
- -
Код Runner::set_alias() Runner::set alias WP-CLI 2.8.0-alpha
private function set_alias( $alias ) { $orig_config = $this->config; $alias_config = $this->aliases[ $alias ]; $this->config = array_merge( $orig_config, $alias_config ); foreach ( $alias_config as $key => $_ ) { if ( isset( $orig_config[ $key ] ) && ! is_null( $orig_config[ $key ] ) ) { $this->assoc_args[ $key ] = $orig_config[ $key ]; } } }