diff --git a/core/modules/user/user.module b/core/modules/user/user.module
index 82584ff..6444a83 100644
--- a/core/modules/user/user.module
+++ b/core/modules/user/user.module
@@ -5,6 +5,7 @@
 use Drupal\Component\Utility\Unicode;
 use Drupal\Core\Entity\EntityInterface;
 use Drupal\Core\Form\FormStateInterface;
+use Drupal\Core\Render\Element;
 use Drupal\Core\Routing\RouteMatchInterface;
 use Drupal\Core\Session\AccountInterface;
 use Drupal\Core\Session\AnonymousUserSession;
@@ -1487,3 +1488,25 @@ function user_logout() {
   // Destroy the current session, and reset $user to the anonymous user.
   session_destroy();
 }
+
+/**
+ * Prepares variables for user templates.
+ *
+ * Default template: user.html.twig.
+ *
+ * @param array $variables
+ *   An associative array containing:
+ *   - elements: An associative array containing the user information and any
+ *     fields attached to the user. Properties used:
+ *     - #user: A \Drupal\user\Entity\User object. The user account of the
+ *       profile being viewed.
+ *   - attributes: HTML attributes for the containing element.
+ */
+function template_preprocess_user(&$variables) {
+  $account = $variables['elements']['#user'];
+
+  // Helpful $content variable for templates.
+  foreach (Element::children($variables['elements']) as $key) {
+    $variables['content'][$key] = $variables['elements'][$key];
+  }
+}
diff --git a/core/modules/user/user.pages.inc b/core/modules/user/user.pages.inc
deleted file mode 100644
index ac8de7d..0000000
--- a/core/modules/user/user.pages.inc
+++ /dev/null
@@ -1,32 +0,0 @@
-<?php
-
-/**
- * @file
- * User page callback file for the user module.
- */
-
-use Drupal\Core\Render\Element;
-use Symfony\Component\HttpFoundation\RedirectResponse;
-use Symfony\Component\HttpKernel\Exception\AccessDeniedHttpException;
-
-/**
- * Prepares variables for user templates.
- *
- * Default template: user.html.twig.
- *
- * @param array $variables
- *   An associative array containing:
- *   - elements: An associative array containing the user information and any
- *     fields attached to the user. Properties used:
- *     - #user: A \Drupal\user\Entity\User object. The user account of the
- *       profile being viewed.
- *   - attributes: HTML attributes for the containing element.
- */
-function template_preprocess_user(&$variables) {
-  $account = $variables['elements']['#user'];
-
-  // Helpful $content variable for templates.
-  foreach (Element::children($variables['elements']) as $key) {
-    $variables['content'][$key] = $variables['elements'][$key];
-  }
-}
