diff --git a/CHANGELOG.txt b/CHANGELOG.txt
index bc9df7a..4f81d30 100644
--- a/CHANGELOG.txt
+++ b/CHANGELOG.txt
@@ -10,7 +10,7 @@ Ubercart 4.x
 * Invoice templates are now named 'uc_order_invoice' to avoid theming conflicts.
 * Order objects now have an interface (OrderInterface) and a set of methods:
     * $order->order_id => $order->id()
-    * $order->uid => $order->getUser(), $order->getUserId() and $order->setUserId()
+    * $order->uid => $order->getOwner(), $order->setOwner(), $order->getOwnerId() and $order->setOwnerId()
     * $order->order_status => $order->getStatusId() and $order->setStatusId()
     * uc_order_status_data($order, 'state') => $order->getStateId()
     * $order->primary_email => $order->getEmail() and $order->setEmail()
diff --git a/payment/uc_authorizenet/uc_authorizenet.module b/payment/uc_authorizenet/uc_authorizenet.module
index 827c4ac..7239ed4 100644
--- a/payment/uc_authorizenet/uc_authorizenet.module
+++ b/payment/uc_authorizenet/uc_authorizenet.module
@@ -260,7 +260,7 @@ function _uc_authorizenet_cim_profile_create_request($order) {
   return array(
     'refId' => substr($order->id() . '-' . REQUEST_TIME, 0, 20),
     'profile' => array(
-      'merchantCustomerId' => substr($order->getUserId(), 0, 20),
+      'merchantCustomerId' => substr($order->getOwnerId(), 0, 20),
       'description' => substr(t('Order @order taking place at @date', array('@order' => $order->id(), '@date' => \Drupal::service('date.formatter')->format(REQUEST_TIME))), 0, 255),
       'email' => substr($order->getEmail(), 0, 255),
       'paymentProfiles' => array(
@@ -453,7 +453,7 @@ function _uc_authorizenet_charge($order, $amount, $data) {
     'x_phone' => substr($order->billing_phone, 0, 25),
     // 'x_fax' => substr('', 0, 25),
     'x_email' => substr($order->getEmail(), 0, 255),
-    'x_cust_id' => $order->getUserId(),
+    'x_cust_id' => $order->getOwnerId(),
     'x_customer_ip' => substr(Drupal::request()->getClientIp(), 0, 15),
 
     // Shipping information.
diff --git a/payment/uc_cybersource/src/Controller/HOPController.php b/payment/uc_cybersource/src/Controller/HOPController.php
index 5e8fc70..4049f40 100644
--- a/payment/uc_cybersource/src/Controller/HOPController.php
+++ b/payment/uc_cybersource/src/Controller/HOPController.php
@@ -77,7 +77,7 @@ class HOPController extends ControllerBase {
           ->execute();
 
         $comment = $this->t('CyberSource request ID: @txn_id', array('@txn_id' => $request_id));
-        uc_payment_enter($order_id, 'cybersource_hop', $payment_amount, $order->getUserId(), NULL, $comment);
+        uc_payment_enter($order_id, 'cybersource_hop', $payment_amount, $order->getOwnerId(), NULL, $comment);
         uc_cart_complete_sale($order);
         uc_order_comment_save($order_id, 0, $this->t('Payment of @amount @currency submitted through CyberSource with request ID @rid.', array('@amount' => $payment_amount, '@currency' => $payment_currency, '@rid' => $request_id)), 'order', 'payment_received');
         break;
diff --git a/payment/uc_cybersource/uc_cybersource.module b/payment/uc_cybersource/uc_cybersource.module
index 45fdf86..acdbee7 100644
--- a/payment/uc_cybersource/uc_cybersource.module
+++ b/payment/uc_cybersource/uc_cybersource.module
@@ -659,7 +659,7 @@ function _uc_cybersource_soap_charge($order, $amount, $data, $cc_type) {
       $billTo->phoneNumber = $order->billing_phone;
     }
     $billTo->email = $order->getEmail();
-    $billTo->customerID = $order->getUserId();
+    $billTo->customerID = $order->getOwnerId();
     $request->billTo = $billTo;
 
     // Add the credit card details if needed.
@@ -889,7 +889,7 @@ function uc_cybersource_uc_calculate_tax($order) {
       $billTo->phoneNumber = $order->billing_phone;
     }
     $billTo->email = $order->getEmail();
-    $billTo->customerID = $order->getUserId();
+    $billTo->customerID = $order->getOwnerId();
     $request->billTo = $billTo;
 
     // Add the shipping information.
diff --git a/payment/uc_payment_pack/src/Tests/PaymentPackTest.php b/payment/uc_payment_pack/src/Tests/PaymentPackTest.php
index 6b6a5da..8095739 100644
--- a/payment/uc_payment_pack/src/Tests/PaymentPackTest.php
+++ b/payment/uc_payment_pack/src/Tests/PaymentPackTest.php
@@ -102,7 +102,7 @@ class PaymentPackTest extends UbercartTestBase {
     $order = \Drupal\uc_order\Entity\Order::load(1);
     $this->assertEqual($order->getPaymentMethodId(), 'check', 'Order has check payment method.');
 
-    $this->drupalGet('user/' . $order->getUserId() . '/orders/' . $order->id());
+    $this->drupalGet('user/' . $order->getOwnerId() . '/orders/' . $order->id());
     $this->assertText('Method: Check', 'Check payment method displayed.');
 
     // Test admin order view - receive check
@@ -124,7 +124,7 @@ class PaymentPackTest extends UbercartTestBase {
     $this->assertText('Clear Date: ' . $formatted, 'Check clear date found.');
 
     // Test that user order view shows check received
-    $this->drupalGet('user/' . $order->getUserId() . '/orders/' . $order->id());
+    $this->drupalGet('user/' . $order->getOwnerId() . '/orders/' . $order->id());
     $this->assertText('Check received');
     $this->assertText('Expected clear date:');
     $this->assertText($formatted, 'Check clear date found.');
@@ -163,7 +163,7 @@ class PaymentPackTest extends UbercartTestBase {
     $order = \Drupal\uc_order\Entity\Order::load(1);
     $this->assertEqual($order->getPaymentMethodId(), 'cod', 'Order has COD payment method.');
 
-    $this->drupalGet('user/' . $order->getUserId() . '/orders/' . $order->id());
+    $this->drupalGet('user/' . $order->getOwnerId() . '/orders/' . $order->id());
     $this->assertText('Method: Cash on delivery', 'COD payment method displayed.');
 
     // Test admin order view
@@ -197,7 +197,7 @@ class PaymentPackTest extends UbercartTestBase {
     $order = \Drupal\uc_order\Entity\Order::load(1);
     $this->assertEqual($order->getPaymentMethodId(), 'other', 'Order has other payment method.');
 
-    $this->drupalGet('user/' . $order->getUserId() . '/orders/' . $order->id());
+    $this->drupalGet('user/' . $order->getOwnerId() . '/orders/' . $order->id());
     $this->assertText('Method: Other', 'Other payment method displayed.');
 
     // Test admin order view
diff --git a/payment/uc_paypal/uc_paypal.pages.inc b/payment/uc_paypal/uc_paypal.pages.inc
index 73b665d..1ddd1e1 100644
--- a/payment/uc_paypal/uc_paypal.pages.inc
+++ b/payment/uc_paypal/uc_paypal.pages.inc
@@ -122,7 +122,7 @@ function uc_paypal_ipn() {
           \Drupal::logger('uc_paypal')->warning('Payment @txn_id for order @order_id did not equal the order total.', array('@txn_id' => $txn_id, '@order_id' => $order->id(), 'link' => l(t('view'), 'admin/store/orders/' . $order->id())));
         }
         $comment = t('PayPal transaction ID: @txn_id', array('@txn_id' => $txn_id));
-        uc_payment_enter($order_id, 'paypal_wps', $payment_amount, $order->getUserId(), NULL, $comment);
+        uc_payment_enter($order_id, 'paypal_wps', $payment_amount, $order->getOwnerId(), NULL, $comment);
         uc_cart_complete_sale($order);
         uc_order_comment_save($order_id, 0, t('PayPal IPN reported a payment of @amount @currency.', array('@amount' => uc_currency_format($payment_amount, FALSE), '@currency' => $payment_currency)));
         break;
@@ -147,7 +147,7 @@ function uc_paypal_ipn() {
       // You, the merchant, refunded the payment.
       case 'Refunded':
         $comment = t('PayPal transaction ID: @txn_id', array('@txn_id' => $txn_id));
-        uc_payment_enter($order_id, 'paypal_wps', $payment_amount, $order->getUserId(), NULL, $comment);
+        uc_payment_enter($order_id, 'paypal_wps', $payment_amount, $order->getOwnerId(), NULL, $comment);
         break;
 
       case 'Reversed':
diff --git a/shipping/uc_shipping/uc_shipping.module b/shipping/uc_shipping/uc_shipping.module
index 5330e33..18c8122 100644
--- a/shipping/uc_shipping/uc_shipping.module
+++ b/shipping/uc_shipping/uc_shipping.module
@@ -259,7 +259,7 @@ function template_preprocess_uc_packing_slip(&$variables) {
   $variables['store_phone'] = $tokens['phone'];
 
   $order = $variables['order'];
-  $variables['order_link'] = l($order->id(), url('user/' . $order->getUserId() . '/orders/' . $order->id(), array('absolute' => TRUE)));
+  $variables['order_link'] = l($order->id(), url('user/' . $order->getOwnerId() . '/orders/' . $order->id(), array('absolute' => TRUE)));
   $variables['order_email'] = $order->getEmail();
   $variables['billing_address'] = $order->getAddress('billing');
   $variables['billing_phone'] = $order->getAddress('billing')->phone;
diff --git a/uc_cart/src/CartManager.php b/uc_cart/src/CartManager.php
index 524503d..0806729 100644
--- a/uc_cart/src/CartManager.php
+++ b/uc_cart/src/CartManager.php
@@ -99,7 +99,7 @@ class CartManager implements CartManagerInterface {
       $order->save();
 
       // Invoke the checkout complete trigger and hook.
-      $account = $order->getUser();
+      $account = $order->getOwner();
       \Drupal::moduleHandler()->invokeAll('uc_checkout_complete', array($order, $account));
       // rules_invoke_event('uc_checkout_complete', $order);
     }
@@ -109,7 +109,7 @@ class CartManager implements CartManagerInterface {
     // Log in new users, if requested.
     if ($type == 'new_user' && $login && $this->currentUser->isAnonymous()) {
       $type = 'new_user_logged_in';
-      user_login_finalize($order->getUser());
+      user_login_finalize($order->getOwner());
     }
 
     $message = \Drupal::config('uc_cart.messages')->get($type);
@@ -134,14 +134,14 @@ class CartManager implements CartManagerInterface {
    */
   protected function completeSaleAccount($order) {
     // Order already has a user ID, so the user was logged in during checkout.
-    if ($order->getUserId()) {
+    if ($order->getOwnerId()) {
       $order->data->complete_sale = 'logged_in';
       return;
     }
 
     // Email address matches an existing account.
     if ($account = user_load_by_mail($order->getEmail())) {
-      $order->setUserId($account->id());
+      $order->setOwner($account);
       $order->data->complete_sale = 'existing_user';
       return;
     }
@@ -182,7 +182,7 @@ class CartManager implements CartManagerInterface {
       \Drupal::service('plugin.manager.mail')->mail('user', $type, $order->getEmail(), uc_store_mail_recipient_langcode($order->getEmail()), array('account' => $account), uc_store_email_from());
     }
 
-    $order->setUserId($account->id());
+    $order->setOwner($account);
     $order->data->new_user_name = $fields['name'];
     $order->data->complete_sale =  'new_user';
   }
diff --git a/uc_cart/src/Controller/CheckoutController.php b/uc_cart/src/Controller/CheckoutController.php
index 5bc50e6..9f8ad8f 100644
--- a/uc_cart/src/Controller/CheckoutController.php
+++ b/uc_cart/src/Controller/CheckoutController.php
@@ -84,7 +84,7 @@ class CheckoutController extends ControllerBase implements ContainerInjectionInt
         // Don't use an existing order if it has changed status or owner, or if
         // there has been no activity for 10 minutes (to prevent identity theft).
         if ($order->getStateId() != 'in_checkout' ||
-            ($this->currentUser()->isAuthenticated() && $this->currentUser()->id() != $order->getUserId()) ||
+            ($this->currentUser()->isAuthenticated() && $this->currentUser()->id() != $order->getOwnerId()) ||
             $order->getChangedTime() < REQUEST_TIME - CartInterface::CHECKOUT_TIMEOUT) {
           if ($order->getStateId() == 'in_checkout' && $order->getChangedTime() < REQUEST_TIME - CartInterface::CHECKOUT_TIMEOUT) {
             // Mark expired orders as abandoned.
diff --git a/uc_cart/src/Plugin/Ubercart/CheckoutPane/CustomerInfoPane.php b/uc_cart/src/Plugin/Ubercart/CheckoutPane/CustomerInfoPane.php
index 037341e..8aa3069 100644
--- a/uc_cart/src/Plugin/Ubercart/CheckoutPane/CustomerInfoPane.php
+++ b/uc_cart/src/Plugin/Ubercart/CheckoutPane/CustomerInfoPane.php
@@ -109,7 +109,7 @@ class CustomerInfoPane extends CheckoutPanePluginBase {
     $order->setEmail($pane['primary_email']);
 
     if ($user->isAuthenticated()) {
-      $order->setUserId($user->id());
+      $order->setOwnerId($user->id());
     }
     else {
       // Check if the email address is already taken.
diff --git a/uc_cart/uc_cart.api.php b/uc_cart/uc_cart.api.php
index fc7c984..90385da 100644
--- a/uc_cart/uc_cart.api.php
+++ b/uc_cart/uc_cart.api.php
@@ -227,7 +227,7 @@ function hook_uc_checkout_complete($order, $account) {
  *   The order object to check out.
  */
 function hook_uc_cart_checkout_start($order) {
-  if (in_array('administrator', $order->getUser()->roles)) {
+  if (in_array('administrator', $order->getOwner()->roles)) {
     drupal_set_message(t('Administrators may not purchase products.', 'error'));
     drupal_goto('cart');
   }
diff --git a/uc_file/uc_file.rules.inc b/uc_file/uc_file.rules.inc
index ece37e0..4383161 100644
--- a/uc_file/uc_file.rules.inc
+++ b/uc_file/uc_file.rules.inc
@@ -270,7 +270,7 @@ function uc_file_action_order_renew($order) {
   $user_downloads = array();
 
   // Load user.
-  if (!($order_user = $order->getUser())) {
+  if (!($order_user = $order->getOwner())) {
     return;
   }
 
diff --git a/uc_order/src/Entity/Order.php b/uc_order/src/Entity/Order.php
index 72c17cb..19282b6 100644
--- a/uc_order/src/Entity/Order.php
+++ b/uc_order/src/Entity/Order.php
@@ -14,6 +14,7 @@ use Drupal\Core\Entity\EntityTypeInterface;
 use Drupal\Core\Field\BaseFieldDefinition;
 use Drupal\uc_order\OrderInterface;
 use Drupal\uc_store\Address;
+use Drupal\user\UserInterface;
 
 /**
  * Defines the order entity class.
@@ -249,21 +250,29 @@ class Order extends ContentEntityBase implements OrderInterface {
   /**
    * {@inheritdoc}
    */
-  public function getUser() {
+  public function getOwner() {
     return $this->get('uid')->entity;
   }
 
   /**
    * {@inheritdoc}
    */
-  public function getUserId() {
+  public function setOwner(UserInterface $account) {
+    $this->set('uid', $account->id());
+    return $this;
+  }
+
+  /**
+   * {@inheritdoc}
+   */
+  public function getOwnerId() {
     return $this->get('uid')->target_id;
   }
 
   /**
    * {@inheritdoc}
    */
-  public function setUserId($uid) {
+  public function setOwnerId($uid) {
     $this->set('uid', $uid);
     return $this;
   }
diff --git a/uc_order/src/OrderAccessControlHandler.php b/uc_order/src/OrderAccessControlHandler.php
index 5614ff8..4c77258 100644
--- a/uc_order/src/OrderAccessControlHandler.php
+++ b/uc_order/src/OrderAccessControlHandler.php
@@ -21,6 +21,8 @@ class OrderAccessControlHandler extends EntityAccessControlHandler {
    * {@inheritdoc}
    */
   protected function checkAccess(EntityInterface $order, $operation, AccountInterface $account) {
+    /** @var \Drupal\uc_order\OrderInterface $order */
+
     switch ($operation) {
       case 'view':
       case 'invoice':
@@ -30,7 +32,7 @@ class OrderAccessControlHandler extends EntityAccessControlHandler {
         }
         // Non-anonymous users can view their own orders and invoices with permission.
         $permission = $operation == 'view' ? 'view own orders' : 'view own invoices';
-        if ($account->id() && $account->id() == $order->getUserId() && $account->hasPermission($permission)) {
+        if ($account->id() && $account->id() == $order->getOwnerId() && $account->hasPermission($permission)) {
           return AccessResult::allowed()->cachePerPermissions()->cachePerUser()->cacheUntilEntityChanges($order);
         }
         return AccessResult::forbidden()->cachePerPermissions()->cachePerUser()->cacheUntilEntityChanges($order);
diff --git a/uc_order/src/OrderForm.php b/uc_order/src/OrderForm.php
index b30f8f8..e7aafba 100644
--- a/uc_order/src/OrderForm.php
+++ b/uc_order/src/OrderForm.php
@@ -23,7 +23,7 @@ class OrderForm extends ContentEntityForm {
 
     $form['#order'] = $order;
     $form['order_id'] = array('#type' => 'hidden', '#value' => $order->id());
-    $form['order_uid'] = array('#type' => 'hidden', '#value' => $order->getUserId());
+    $form['order_uid'] = array('#type' => 'hidden', '#value' => $order->getOwnerId());
 
     $modified = $form_state->getValue('order_modified') ?: $order->getChangedTime();
     $form['order_modified'] = array('#type' => 'hidden', '#value' => $modified);
diff --git a/uc_order/src/OrderInterface.php b/uc_order/src/OrderInterface.php
index e72f8c5..6d89fa3 100644
--- a/uc_order/src/OrderInterface.php
+++ b/uc_order/src/OrderInterface.php
@@ -10,11 +10,12 @@ namespace Drupal\uc_order;
 use Drupal\Core\Entity\EntityChangedInterface;
 use Drupal\Core\Entity\ContentEntityInterface;
 use Drupal\uc_store\Address;
+use Drupal\user\EntityOwnerInterface;
 
 /**
  * Provides an interface defining an Ubercart order entity.
  */
-interface OrderInterface extends ContentEntityInterface, EntityChangedInterface {
+interface OrderInterface extends ContentEntityInterface, EntityChangedInterface, EntityOwnerInterface {
 
   /**
    * Gets the order creation timestamp.
@@ -61,33 +62,6 @@ interface OrderInterface extends ContentEntityInterface, EntityChangedInterface
   public function getDisplayLineItems();
 
   /**
-   * Returns the order user entity.
-   *
-   * @return \Drupal\user\UserInterface
-   *   The user entity.
-   */
-  public function getUser();
-
-  /**
-   * Returns the order user ID.
-   *
-   * @return int
-   *   The user ID.
-   */
-  public function getUserId();
-
-  /**
-   * Sets the order user ID.
-   *
-   * @param int $uid
-   *   The user ID.
-   *
-   * @return \Drupal\uc_order\OrderInterface
-   *   The called owner entity.
-   */
-  public function setUserId($uid);
-
-  /**
    * Returns the order status.
    *
    * @return \Drupal\uc_order\OrderStatusInterface
diff --git a/uc_order/src/Tests/OrderTest.php b/uc_order/src/Tests/OrderTest.php
index 5d918fb..9aaa59c 100644
--- a/uc_order/src/Tests/OrderTest.php
+++ b/uc_order/src/Tests/OrderTest.php
@@ -37,7 +37,7 @@ class OrderTest extends UbercartTestBase {
     // Test defaults.
     $order = Order::create();
     $order->save();
-    $this->assertEqual($order->getUserId(), 0, 'New order is anonymous.');
+    $this->assertEqual($order->getOwnerId(), 0, 'New order is anonymous.');
     $this->assertEqual($order->getStatusId(), 'in_checkout', 'New order is in checkout.');
 
     $order = Order::create(array(
@@ -45,7 +45,7 @@ class OrderTest extends UbercartTestBase {
       'order_status' => uc_order_state_default('completed'),
     ));
     $order->save();
-    $this->assertEqual($order->getUserId(), $this->customer->id(), 'New order has correct uid.');
+    $this->assertEqual($order->getOwnerId(), $this->customer->id(), 'New order has correct uid.');
     $this->assertEqual($order->getStatusId(), 'completed', 'New order is marked completed.');
 
     // Test deletion.
@@ -56,7 +56,7 @@ class OrderTest extends UbercartTestBase {
 
   public function testOrderEntity() {
     $order = Order::create();
-    $this->assertEqual($order->getUserId(), 0, 'New order is anonymous.');
+    $this->assertEqual($order->getOwnerId(), 0, 'New order is anonymous.');
     $this->assertEqual($order->getStatusId(), 'in_checkout', 'New order is in checkout.');
 
     $name = $this->randomMachineName();
@@ -66,7 +66,7 @@ class OrderTest extends UbercartTestBase {
       'billing_first_name' => $name,
       'billing_last_name' => $name,
     ));
-    $this->assertEqual($order->getUserId(), $this->customer->id(), 'New order has correct uid.');
+    $this->assertEqual($order->getOwnerId(), $this->customer->id(), 'New order has correct uid.');
     $this->assertEqual($order->getStatusId(), 'completed', 'New order is marked completed.');
     $this->assertEqual($order->getAddress('billing')->first_name, $name, 'New order has correct name.');
     $this->assertEqual($order->getAddress('billing')->last_name, $name, 'New order has correct name.');
@@ -154,7 +154,7 @@ class OrderTest extends UbercartTestBase {
     $this->assertText(Unicode::strtoupper($delivery_address->street2), 'Delivery street 2 found.');
     $this->assertText(Unicode::strtoupper($delivery_address->city), 'Delivery city found.');
 
-    $this->assertLink($order->getUserId(), 0, 'Link to customer account page found.');
+    $this->assertLink($order->getOwnerId(), 0, 'Link to customer account page found.');
     $this->assertLink($order->getEmail(), 0, 'Link to customer email address found.');
   }
 
diff --git a/uc_order/uc_order.api.php b/uc_order/uc_order.api.php
index 19fd4b0..80aefe5 100644
--- a/uc_order/uc_order.api.php
+++ b/uc_order/uc_order.api.php
@@ -90,7 +90,7 @@ function hook_uc_line_item() {
  *   The order object containing the line item.
  */
 function hook_uc_line_item_alter(&$item, $order) {
-  rules_invoke_event('calculate_line_item_discounts', $item, $order->getUser());
+  rules_invoke_event('calculate_line_item_discounts', $item, $order->getOwner());
 }
 
 /**
diff --git a/uc_order/uc_order.order_pane.inc b/uc_order/uc_order.order_pane.inc
index ee88f40..8c9354a 100644
--- a/uc_order/uc_order.order_pane.inc
+++ b/uc_order/uc_order.order_pane.inc
@@ -30,7 +30,7 @@ function uc_order_pane_print_button($op, $order, &$form = NULL, FormStateInterfa
       if ($order->access('invoice')) {
         $link = t('Click to open a window with a printable invoice.');
         $build = array(
-          '#markup' => \Drupal::l($link, new Url('uc_order.user_invoice_print', ['user' => $order->getUserId(), 'uc_order' => $order->id()], array(
+          '#markup' => \Drupal::l($link, new Url('uc_order.user_invoice_print', ['user' => $order->getOwnerId(), 'uc_order' => $order->id()], array(
             'attributes' => array(
               'onclick' => "window.open(this.href, '" . t('Invoice') . "', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=1,width=600,height=480,left=50,top=50'); return false;",
             ),
@@ -136,13 +136,13 @@ function uc_order_pane_bill_to($op, $order, &$form = NULL, FormStateInterface $f
 function uc_order_pane_customer($op, $order, &$form = NULL, FormStateInterface $form_state = NULL) {
   switch ($op) {
     case 'view':
-      if ($order->getUserId()) {
+      if ($order->getOwnerId()) {
         $build['uid'] = array(
           '#type' => 'link',
           '#prefix' => t('Customer number') . ': ',
           '#suffix' => '<br />',
-          '#title' => $order->getUserId(),
-          '#url' => Url::fromRoute('entity.user.canonical', ['user' => $order->getUserId()]),
+          '#title' => $order->getOwnerId(),
+          '#url' => Url::fromRoute('entity.user.canonical', ['user' => $order->getOwnerId()]),
         );
       }
       $build['primary_email'] = array(
@@ -156,12 +156,12 @@ function uc_order_pane_customer($op, $order, &$form = NULL, FormStateInterface $
     case 'edit-form':
       $form['customer']['uid'] = array(
         '#type' => 'hidden',
-        '#default_value' => $order->getUserId(),
+        '#default_value' => $order->getOwnerId(),
       );
       $form['customer']['uid_text'] = array(
         '#type' => 'textfield',
         '#title' => t('Customer number'),
-        '#default_value' => $order->getUserId(),
+        '#default_value' => $order->getOwnerId(),
         '#maxlength' => 10,
         '#size' => 10,
         '#disabled' => TRUE,
@@ -189,7 +189,7 @@ function uc_order_pane_customer($op, $order, &$form = NULL, FormStateInterface $
       return $output;
 
     case 'edit-process':
-      $order->setUserId($form_state->getValue('uid'));
+      $order->setOwnerId($form_state->getValue('uid'));
       $order->setEmail($form_state->getValue('primary_email'));
   }
 }
diff --git a/uc_order/uc_order.tokens.inc b/uc_order/uc_order.tokens.inc
index a5b744c..00e49df 100644
--- a/uc_order/uc_order.tokens.inc
+++ b/uc_order/uc_order.tokens.inc
@@ -152,7 +152,7 @@ function uc_order_tokens($type, $tokens, array $data, array $options, Bubbleable
   if ($type == 'uc_order' && !empty($data['uc_order'])) {
     /** @var \Drupal\uc_order\OrderInterface $order */
     $order = $data['uc_order'];
-    $path = 'user/' . $order->getUserId() . '/orders/' . $order->id();
+    $path = 'user/' . $order->getOwnerId() . '/orders/' . $order->id();
     $admin_path = 'admin/store/orders/' . $order->id();
 
     foreach ($tokens as $name => $original) {
@@ -288,7 +288,7 @@ function uc_order_tokens($type, $tokens, array $data, array $options, Bubbleable
           break;
 
         case 'customer':
-          $replacements[$original] = $order->getUserId();
+          $replacements[$original] = $order->getOwnerId();
           break;
 
         case 'created':
@@ -327,7 +327,7 @@ function uc_order_tokens($type, $tokens, array $data, array $options, Bubbleable
     }
 
     if ($customer_tokens = $token_service->findWithPrefix($tokens, 'customer')) {
-      $replacements += $token_service->generate('user', $customer_tokens, ['user' => $order->getUser()], $options, $bubbleable_metadata);
+      $replacements += $token_service->generate('user', $customer_tokens, ['user' => $order->getOwner()], $options, $bubbleable_metadata);
     }
 
     if ($created_tokens = $token_service->findWithPrefix($tokens, 'created')) {
diff --git a/uc_role/src/Tests/RoleTest.php b/uc_role/src/Tests/RoleTest.php
index e1a64ea..147ddbf 100644
--- a/uc_role/src/Tests/RoleTest.php
+++ b/uc_role/src/Tests/RoleTest.php
@@ -38,7 +38,7 @@ class RoleTest extends UbercartTestBase {
 
     // Test that the role was granted.
     // @todo Re-enable when Rules is available.
-    // $this->assertTrue($order->getUser()->hasRole($rid), 'Existing user was granted role.');
+    // $this->assertTrue($order->getOwner()->hasRole($rid), 'Existing user was granted role.');
 
     // Test that the email is correct.
     $role = \Drupal\user\Entity\Role::load($rid);
@@ -46,7 +46,7 @@ class RoleTest extends UbercartTestBase {
     // $this->assertMailString('subject', $role->label(), 4, 'Role assignment email mentions role in subject line.');
 
     // Test that the role product / user relation is deleted with the user.
-    user_delete($order->getUserId());
+    user_delete($order->getOwnerId());
 
     // Run cron to ensure deleted users are handled correctly.
     $this->cronRun();
diff --git a/uc_role/uc_role.rules.inc b/uc_role/uc_role.rules.inc
index 8355bd7..cb86fb2 100644
--- a/uc_role/uc_role.rules.inc
+++ b/uc_role/uc_role.rules.inc
@@ -329,7 +329,7 @@ function uc_role_action_user_email($account, $role_expiration, $from, $addresses
  */
 function uc_role_action_order_renew($order, $message) {
   // Load the order's user and exit if not available.
-  if (!($account = $order->getUser())) {
+  if (!($account = $order->getOwner())) {
     return;
   }
 
diff --git a/uc_stock/uc_stock.module b/uc_stock/uc_stock.module
index 1b6e182..dc9572b 100644
--- a/uc_stock/uc_stock.module
+++ b/uc_stock/uc_stock.module
@@ -130,7 +130,7 @@ function uc_stock_is_active($sku) {
 function _uc_stock_send_mail($order, $node, $stock) {
   $token_service = \Drupal::token();
 
-  $account = $order->getUser();
+  $account = $order->getOwner();
   $token_filters = array('uc_order' => $order, 'user' => $account, 'uc_stock' => $stock, 'node' => $node);
 
   $to = \Drupal::config('uc_stock.settings')->get('recipients');
