) ), true ); } /** * Get Webhook statuses. * * @since 2.3.0 * @return array */ function wc_get_webhook_statuses() { return apply_filters( 'woocommerce_webhook_statuses', array( 'active' => __( 'Active', 'woocommerce' ), 'paused' => __( 'Paused', 'woocommerce' ), 'disabled' => __( 'Disabled', 'woocommerce' ), ) ); } /** * Load webhooks. * * @since 3.3.0 * @throws Exception If webhook cannot be read/found and $data parameter of WC_Webhook class constructor is set. * @param string $status Optional - status to filter results by. Must be a key in return value of @see wc_get_webhook_statuses(). @since 3.5.0. * @param null|int $limit Limit number of webhooks loaded. @since 3.6.0. * @return bool */ function wc_load_webhooks( $status = '', $limit = null ) { // short-circuit if webhooks should not be loaded at all. if ( ! is_null( $limit ) && $limit <= 0 ) { return false; } $data_store = WC_Data_Store::load( 'webhook' ); $webhooks = $data_store->get_webhooks_ids( $status ); $loaded = 0; foreach ( $webhooks as $webhook_id ) { if ( ! is_null( $limit ) && $loaded >= $limit ) { break; } $webhook = new WC_Webhook( $webhook_id ); $webhook->enqueue(); $loaded ++; } return 0 < $loaded; } /** * Get webhook. * * @param int|WC_Webhook $id Webhook ID or object. * @throws Exception If webhook cannot be read/found and $data parameter of WC_Webhook class constructor is set. * @return WC_Webhook|null */ function wc_get_webhook( $id ) { $webhook = new WC_Webhook( $id ); return 0 !== $webhook->get_id() ? $webhook : null; } /** * Get webhoook REST API versions. * * @since 3.5.1 * @return array */ function wc_get_webhook_rest_api_versions() { return array( 'wp_api_v1', 'wp_api_v2', 'wp_api_v3', ); }
Fatal error: Uncaught Error: Class "WP_Syntex\Polylang\Options\Business\Rewrite" not found in /htdocs/wp-content/plugins/polylang/include/Options/Options.php:101 Stack trace: #0 [internal function]: WP_Syntex\Polylang\Options\Options->register('WP_Syntex\\Polyl...') #1 /htdocs/wp-content/plugins/polylang/include/Options/Registry.php(51): array_map(Array, Array) #2 /htdocs/wp-includes/class-wp-hook.php(326): WP_Syntex\Polylang\Options\Registry::register(Object(WP_Syntex\Polylang\Options\Options)) #3 /htdocs/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters('', Array) #4 /htdocs/wp-includes/plugin.php(517): WP_Hook->do_action(Array) #5 /htdocs/wp-content/plugins/polylang/include/Options/Options.php(567): do_action('pll_init_option...', Object(WP_Syntex\Polylang\Options\Options), 1) #6 /htdocs/wp-content/plugins/polylang/include/Options/Options.php(81): WP_Syntex\Polylang\Options\Options->init_options_for_current_blog() #7 /htdocs/wp-content/plugins/polylang/include/class-polylang.php(174): WP_Syntex\Polylang\Options\Options->__construct() #8 /htdocs/wp-includes/class-wp-hook.php(324): Polylang->init('') #9 /htdocs/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters(NULL, Array) #10 /htdocs/wp-includes/plugin.php(517): WP_Hook->do_action(Array) #11 /htdocs/wp-settings.php(559): do_action('plugins_loaded') #12 /htdocs/wp-config.php(111): require_once('/htdocs/wp-sett...') #13 /htdocs/wp-load.php(50): require_once('/htdocs/wp-conf...') #14 /htdocs/wp-blog-header.php(13): require_once('/htdocs/wp-load...') #15 /htdocs/index.php(17): require('/htdocs/wp-blog...') #16 {main} thrown in /htdocs/wp-content/plugins/polylang/include/Options/Options.php on line 101