Updated High Performance Order Storage Upgrade Recipe Book (markdown)
parent
ab02030682
commit
ef86a7139c
|
@ -172,7 +172,7 @@ use Automattic\WooCommerce\Internal\DataStores\Orders\CustomOrdersTableControlle
|
|||
add_action( 'add_meta_boxes', 'add_xyz_metabox' );
|
||||
|
||||
function add_xyz_metabox() {
|
||||
$screen = wc_get_container()->get( CustomOrdersTableController::class )->custom_orders_table_usage_is_enabled()
|
||||
$screen = class_exists( '\Automattic\WooCommerce\Internal\DataStores\Orders\CustomOrdersTableController' ) && wc_get_container()->get( CustomOrdersTableController::class )->custom_orders_table_usage_is_enabled()
|
||||
? wc_get_page_screen_id( 'shop-order' )
|
||||
: 'shop_order';
|
||||
|
||||
|
|
Loading…
Reference in New Issue