diff --git a/includes/admin/meta-boxes/class-wc-meta-box-product-images.php b/includes/admin/meta-boxes/class-wc-meta-box-product-images.php index 7f63034ca47..f3b788a09b9 100644 --- a/includes/admin/meta-boxes/class-wc-meta-box-product-images.php +++ b/includes/admin/meta-boxes/class-wc-meta-box-product-images.php @@ -25,20 +25,18 @@ class WC_Meta_Box_Product_Images { * @param WP_Post $post */ public static function output( $post ) { + global $thepostid, $product_object; + + $thepostid = $post->ID; + $product_object = $thepostid ? wc_get_product( $thepostid ) : new WC_Product; + wp_nonce_field( 'woocommerce_save_data', 'woocommerce_meta_nonce' ); ?>