diff -u b/core/modules/shortcut/lib/Drupal/shortcut/Form/SetSwitch.php b/core/modules/shortcut/lib/Drupal/shortcut/Form/SetSwitch.php --- b/core/modules/shortcut/lib/Drupal/shortcut/Form/SetSwitch.php +++ b/core/modules/shortcut/lib/Drupal/shortcut/Form/SetSwitch.php @@ -80,6 +80,8 @@ return String::checkPlain($set->label()); }, $this->storageController->load()); + $current_set = shortcut_current_displayed_set($this->account->getBCEntity()); + // Only administrators can add shortcut sets. $add_access = user_access('administer shortcuts'); if ($add_access) { @@ -92,7 +94,7 @@ '#type' => 'radios', '#title' => $account_is_user ? t('Choose a set of shortcuts to use') : t('Choose a set of shortcuts for this user'), '#options' => $options, - '#default_value' => shortcut_current_displayed_set($this->account)->id(), + '#default_value' => $current_set->id(), ); $form['label'] = array( @@ -120,7 +122,7 @@ ); if (!$account_is_user) { - $default_set = shortcut_default_set($this->account); + $default_set = shortcut_default_set($this->account->getBCEntity()); $form['new']['#description'] = t('The new set is created by copying items from the %default set.', array('%default' => $default_set->label())); }