From ad6c9a7099f6c26866107a56715fdbaf11793657 Mon Sep 17 00:00:00 2001 From: vedanshujain Date: Wed, 2 Feb 2022 15:14:34 +0530 Subject: [PATCH] Fixups for typo and unintended code. --- plugins/woocommerce/includes/class-wc-install.php | 2 +- .../Internal/DataStores/Orders/FeatureController.php | 2 +- .../DataStores/Orders/OrdersTableDataStore.php | 12 +----------- 3 files changed, 3 insertions(+), 13 deletions(-) diff --git a/plugins/woocommerce/includes/class-wc-install.php b/plugins/woocommerce/includes/class-wc-install.php index 0b2b08a114f..c57221027dd 100644 --- a/plugins/woocommerce/includes/class-wc-install.php +++ b/plugins/woocommerce/includes/class-wc-install.php @@ -364,7 +364,7 @@ class WC_Install { /** * Verify if the table(s) already exists. * - * @param string $schema Schema definition to check agains. + * @param string $schema Schema definition to check against. * * return array List of missing tables. */ diff --git a/plugins/woocommerce/src/Internal/DataStores/Orders/FeatureController.php b/plugins/woocommerce/src/Internal/DataStores/Orders/FeatureController.php index ec56f057a2a..bb467c68228 100644 --- a/plugins/woocommerce/src/Internal/DataStores/Orders/FeatureController.php +++ b/plugins/woocommerce/src/Internal/DataStores/Orders/FeatureController.php @@ -35,7 +35,7 @@ class FeatureController { * * @var DataSyncrhonizer */ - public $data_synchronizer; + private $data_synchronizer; /** * Is the feature visible? diff --git a/plugins/woocommerce/src/Internal/DataStores/Orders/OrdersTableDataStore.php b/plugins/woocommerce/src/Internal/DataStores/Orders/OrdersTableDataStore.php index 62cfa56a976..f72229be128 100644 --- a/plugins/woocommerce/src/Internal/DataStores/Orders/OrdersTableDataStore.php +++ b/plugins/woocommerce/src/Internal/DataStores/Orders/OrdersTableDataStore.php @@ -114,17 +114,7 @@ class OrdersTableDataStore extends \Abstract_WC_Order_Data_Store_CPT implements * @param \WC_Order $order */ public function create( &$order ) { - global $wpdb; - $order->set_version( Constants::get_constant( 'WC_VERSION' ) ); - $order->set_currency( $order->get_currency() ? $order->get_currency() : get_woocommerce_currency() ); - if ( ! $order->get_date_created( 'edit' ) ) { - $order->set_date_created( time() ); - } - - $table_name = $this->get_orders_table_name(); - $insert_query = " - INSERT INTO $table_name () - "; + throw new \Exception( 'Unimplemented' ); } public function update( &$order ) {