diff --git a/core/includes/install.core.inc b/core/includes/install.core.inc
index 9b95a47..49fe0d8 100644
--- a/core/includes/install.core.inc
+++ b/core/includes/install.core.inc
@@ -403,6 +403,11 @@ function install_begin_request(&$install_state) {
       ->register('keyvalue.expirable.null', 'Drupal\Core\KeyValueStore\KeyValueNullExpirableFactory');
     $conf['keyvalue_expirable_default'] = 'keyvalue.expirable.null';
 
+    // Set the request in the container to the new created Request above
+    // so it is available to the rest of the installation process.
+    $container
+      ->set('request', $request);
+
     // Register Twig template engine for use during install.
     CoreBundle::registerTwig($container);
 
diff --git a/core/modules/user/lib/Drupal/user/Plugin/views/field/Name.php b/core/modules/user/lib/Drupal/user/Plugin/views/field/Name.php
index 33e274c..87d9983 100644
--- a/core/modules/user/lib/Drupal/user/Plugin/views/field/Name.php
+++ b/core/modules/user/lib/Drupal/user/Plugin/views/field/Name.php
@@ -85,7 +85,7 @@ function render_link($data, $values) {
       }
       elseif (!empty($this->options['link_to_user'])) {
         $account->name = $this->get_value($values);
-        return theme('username', array('account' => $account));
+        return array('#theme' => 'username', 'account' => $account);
       }
     }
     // If we want a formatted username, do that.
diff --git a/core/modules/user/user.admin.inc b/core/modules/user/user.admin.inc
index 9946ae2..884f77d 100644
--- a/core/modules/user/user.admin.inc
+++ b/core/modules/user/user.admin.inc
@@ -222,7 +222,10 @@ function user_admin_account() {
     $options[$account->uid] = array(
       'username' => theme('username', array('account' => $account)),
       'status' =>  $status[$account->status],
-      'roles' => theme('item_list', array('items' => $users_roles)),
+      'roles' => array(
+        '#theme' => 'item_list',
+        '#items' => $users_roles,
+      )
       'member_for' => format_interval(REQUEST_TIME - $account->created),
       'access' =>  $account->access ? t('@time ago', array('@time' => format_interval(REQUEST_TIME - $account->access))) : t('never'),
     );
@@ -254,7 +257,9 @@ function user_admin_account() {
     '#options' => $options,
     '#empty' => t('No people available.'),
   );
-  $form['pager'] = array('#markup' => theme('pager'));
+  $form['pager'] = array(
+    '#markup' => array('#theme' => 'pager'),
+  );
 
   return $form;
 }
@@ -340,7 +345,11 @@ function user_admin_permissions($form, $form_state, $rid = NULL) {
         $form['permission'][$perm] = array(
           '#type' => 'item',
           '#markup' => $perm_item['title'],
-          '#description' => theme('user_permission_description', array('permission_item' => $perm_item, 'hide' => $hide_descriptions)),
+          '#description' => array(
+            '#theme' => 'user_permission_description',
+            '#permission_item' =>$perm_item,
+            'hide' => $hide_descriptions,
+          ),
         );
         foreach ($role_names as $rid => $name) {
           // Builds arrays for checked boxes for each role
@@ -424,8 +433,13 @@ function theme_user_admin_permissions($variables) {
   foreach (element_children($form['role_names']) as $rid) {
     $header[] = array('data' => drupal_render($form['role_names'][$rid]), 'class' => array('checkbox'));
   }
-  $output = theme('system_compact_link');
-  $output .= theme('table', array('header' => $header, 'rows' => $rows, 'attributes' => array('id' => 'permissions')));
+  $output = array('#theme' => 'system_compact_link');
+    $output .= array(
+      '#theme' => 'table',
+      'header' => $header,
+      'rows' => $rows,
+      'attributes' => array('id' => 'permissions')),
+    );
   $output .= drupal_render_children($form);
   return $output;
 }
