diff --git a/core/lib/Drupal/Core/Path/AliasManager.php b/core/lib/Drupal/Core/Path/AliasManager.php index be36686..01fd1b6 100644 --- a/core/lib/Drupal/Core/Path/AliasManager.php +++ b/core/lib/Drupal/Core/Path/AliasManager.php @@ -317,7 +317,7 @@ protected function pathAliasWhitelistRebuild($source = NULL) { * The language code. * * @return bool - * TRUE if alias exists, false otherwise. + * TRUE if alias exists, FALSE otherwise. */ public function checkAliasExists($pid, $alias, $langcode) { $query = 'SELECT pid FROM {url_alias} WHERE pid != :pid AND alias = :alias AND langcode = :langcode LIMIT 1'; diff --git a/core/modules/path/lib/Drupal/path/Controller/PathController.php b/core/modules/path/lib/Drupal/path/Controller/PathController.php index 1302854..fca2d8a 100644 --- a/core/modules/path/lib/Drupal/path/Controller/PathController.php +++ b/core/modules/path/lib/Drupal/path/Controller/PathController.php @@ -26,7 +26,7 @@ class PathController extends ControllerBase implements ContainerInjectionInterfa * * @var \Drupal\Core\Database\Connection */ - protected $connection; + protected $databaseConnection; /** * The alias service. @@ -38,13 +38,13 @@ class PathController extends ControllerBase implements ContainerInjectionInterfa /** * Constructs a PathController object. * - * @param \Drupal\Core\Database\Connection $connection + * @param \Drupal\Core\Database\Connection $database_connection * The database connection service. * @param \Drupal\Core\Path\AliasManagerInterface $alias_manager * The path alias manager service. */ - public function __construct(Connection $connection, AliasManagerInterface $alias_manager ) { - $this->connection = $connection; + public function __construct(Connection $database_connection, AliasManagerInterface $alias_manager ) { + $this->databaseConnection = $database_connection; $this->aliasManager = $alias_manager; } @@ -80,7 +80,7 @@ public function adminOverview($alias = NULL) { // Enable language column if language.module is enabled or if we have any // alias with a language. - $query = $this->connection->select('url_alias', 'u') + $query = $this->databaseConnection->select('url_alias', 'u') ->fields('u', array('pid')) ->condition('langcode', Language::LANGCODE_NOT_SPECIFIED, '<>') ->range(0,1); @@ -95,7 +95,7 @@ public function adminOverview($alias = NULL) { } $header[] = $this->t('Operations'); - $query = $this->connection->select('url_alias') + $query = $this->databaseConnection->select('url_alias') ->extend('\Drupal\Core\Database\Query\PagerSelectExtender') ->extend('\Drupal\Core\Database\Query\TableSortExtender'); if ($alias) { diff --git a/core/modules/path/lib/Drupal/path/Form/EditForm.php b/core/modules/path/lib/Drupal/path/Form/EditForm.php index 45b0604..ef19532 100644 --- a/core/modules/path/lib/Drupal/path/Form/EditForm.php +++ b/core/modules/path/lib/Drupal/path/Form/EditForm.php @@ -168,7 +168,7 @@ public function validateForm(array &$form, array &$form_state) { // Language is only set if language.module is enabled, otherwise save for all // languages. $langcode = isset($form_state['values']['langcode']) ? $form_state['values']['langcode'] : Language::LANGCODE_NOT_SPECIFIED; - $source = &$form_state['values']['source']; + $source =& $form_state['values']['source']; $source = $this->aliasManager->getSystemPath($source, $langcode); $alias_exists = $this->aliasManager->checkAliasExists($pid, $alias, $langcode); @@ -212,4 +212,5 @@ public function deleteForm(array &$form, array &$form_state) { } $form_state['redirect'] = array('admin/config/search/path/delete/' . $pid, array('query' => $destination)); } + }