You are here

public function LanguageNeutralAliasesStorage::load in Language neutral aliases 8

Fetches a specific URL alias from the database.

The default implementation performs case-insensitive matching on the 'source' and 'alias' strings.

Parameters

array $conditions: An array of query conditions.

Return value

array|false FALSE if no alias was found or an associative array containing the following keys:

  • source (string): The internal system path with a starting slash.
  • alias (string): The URL alias with a starting slash.
  • pid (int): Unique path alias identifier.
  • langcode (string): The language code of the alias.

Overrides AliasStorage::load

File

src/LanguageNeutralAliasesStorage.php, line 56

Class

LanguageNeutralAliasesStorage
Language neutral alias storage.

Namespace

Drupal\language_neutral_aliases

Code

public function load($conditions) {

  // Callers might have opinions about what language version they want, ignore
  // them.
  $conditions['langcode'] = LanguageInterface::LANGCODE_NOT_SPECIFIED;
  return parent::load($conditions);
}