Automattic\WooCommerce\Admin\API
OnboardingPlugins::log_plugins_install_error()
Метод класса: OnboardingPlugins{}
Хуков нет.
Возвращает
null
. Ничего (null).
Использование
$OnboardingPlugins = new OnboardingPlugins(); $OnboardingPlugins->log_plugins_install_error( $slug, $api, $result, $upgrader );
- $slug (обязательный)
- -
- $api (обязательный)
- -
- $result (обязательный)
- -
- $upgrader (обязательный)
- -
Код OnboardingPlugins::log_plugins_install_error() OnboardingPlugins::log plugins install error WC 9.4.2
public function log_plugins_install_error( $slug, $api, $result, $upgrader ) { $properties = array( 'error_message' => sprintf( /* translators: %s: plugin slug (example: woocommerce-services) */ __( 'The requested plugin `%s` could not be installed.', 'woocommerce' ), $slug ), 'type' => 'plugin_info_api_error', 'slug' => $slug, 'api_version' => $api->version, 'api_download_link' => $api->download_link, 'upgrader_skin_message' => implode( ',', $upgrader->skin->get_upgrade_messages() ), 'result' => is_wp_error( $result ) ? $result->get_error_message() : 'null', ); wc_admin_record_tracks_event( 'coreprofiler_install_plugin_error', $properties ); }