Commit 1d6e7e25 authored by catch's avatar catch

Issue #2851394 by GoZ, hgunicamp, oknate, jungle, wolffereast, tameeshb,...

Issue #2851394 by GoZ, hgunicamp, oknate, jungle, wolffereast, tameeshb, mmatsoo, ridhimaabrol24, jofitz, swarad07, tanc, shaktik, dimaro, shashikant_chauhan, MerryHamster, quietone, nitesh624, martin_q, boaloysius, gaurav.kapoor, nitvirus, ankithashetty, Munavijayalakshmi, kostyashupenko, leolando.tan, amit.drupal, ravi.shankar, akashkrishnan01, Swapnil_Kotwal, Saviktor, mrinalini9, anmolgoyal74, Venkatesh Rajan.J, shimpy, lomasr, Dinesh18, shubham.prakash, mahtab_alam, markdorison, cilefen, longwave, bleen, xjm, alexpott, gmaltoni: Fix grammar 'a' to 'an' when necessary
parent 0ea2e4d0
...@@ -143,7 +143,7 @@ function drupal_find_theme_functions($cache, $prefixes) { ...@@ -143,7 +143,7 @@ function drupal_find_theme_functions($cache, $prefixes) {
// Find theme functions that implement possible "suggestion" variants of // Find theme functions that implement possible "suggestion" variants of
// registered theme hooks and add those as new registered theme hooks. // registered theme hooks and add those as new registered theme hooks.
// The 'pattern' key defines a common prefix that all suggestions must // The 'pattern' key defines a common prefix that all suggestions must
// start with. The default is the name of the hook followed by '__'. An // start with. The default is the name of the hook followed by '__'. A
// 'base hook' key is added to each entry made for a found suggestion, // 'base hook' key is added to each entry made for a found suggestion,
// so that common functionality can be implemented for all suggestions of // so that common functionality can be implemented for all suggestions of
// the same base hook. To keep things simple, deep hierarchy of // the same base hook. To keep things simple, deep hierarchy of
......
...@@ -15,7 +15,7 @@ class InvalidPluginDefinitionException extends PluginException { ...@@ -15,7 +15,7 @@ class InvalidPluginDefinitionException extends PluginException {
protected $pluginId; protected $pluginId;
/** /**
* Constructs a InvalidPluginDefinitionException. * Constructs an InvalidPluginDefinitionException.
* *
* For the remaining parameters see \Exception. * For the remaining parameters see \Exception.
* *
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
class PluginNotFoundException extends PluginException { class PluginNotFoundException extends PluginException {
/** /**
* Construct an PluginNotFoundException exception. * Construct a PluginNotFoundException exception.
* *
* For the remaining parameters see \Exception. * For the remaining parameters see \Exception.
* *
......
...@@ -45,8 +45,8 @@ class Html { ...@@ -45,8 +45,8 @@ class Html {
* <command> tag anymore. * <command> tag anymore.
* See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/command. * See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/command.
* - The 'manifest' attribute is omitted because it only exists for the <html> * - The 'manifest' attribute is omitted because it only exists for the <html>
* tag. That tag only makes sense in a HTML-served-as-HTML context, in which * tag. That tag only makes sense in an HTML-served-as-HTML context, in
* case relative URLs are guaranteed to work. * which case relative URLs are guaranteed to work.
* *
* @see https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes
* @see https://stackoverflow.com/questions/2725156/complete-list-of-html-tag-attributes-which-have-a-url-value * @see https://stackoverflow.com/questions/2725156/complete-list-of-html-tag-attributes-which-have-a-url-value
......
...@@ -242,14 +242,14 @@ public static function isExternal($path) { ...@@ -242,14 +242,14 @@ public static function isExternal($path) {
* TRUE if the URL has the same domain and base path. * TRUE if the URL has the same domain and base path.
* *
* @throws \InvalidArgumentException * @throws \InvalidArgumentException
* Exception thrown when a either $url or $bath_url are not fully qualified. * Exception thrown when either $url or $base_url are not fully qualified.
*/ */
public static function externalIsLocal($url, $base_url) { public static function externalIsLocal($url, $base_url) {
// Some browsers treat \ as / so normalize to forward slashes. // Some browsers treat \ as / so normalize to forward slashes.
$url = str_replace('\\', '/', $url); $url = str_replace('\\', '/', $url);
// Leading control characters may be ignored or mishandled by browsers, so // Leading control characters may be ignored or mishandled by browsers, so
// assume such a path may lead to an non-local location. The \p{C} character // assume such a path may lead to a non-local location. The \p{C} character
// class matches all UTF-8 control, unassigned, and private characters. // class matches all UTF-8 control, unassigned, and private characters.
if (preg_match('/^\p{C}/u', $url) !== 0) { if (preg_match('/^\p{C}/u', $url) !== 0) {
return FALSE; return FALSE;
......
...@@ -55,7 +55,7 @@ class AccessManager implements AccessManagerInterface { ...@@ -55,7 +55,7 @@ class AccessManager implements AccessManagerInterface {
protected $checkProvider; protected $checkProvider;
/** /**
* Constructs a AccessManager instance. * Constructs an AccessManager instance.
* *
* @param \Drupal\Core\Routing\RouteProviderInterface $route_provider * @param \Drupal\Core\Routing\RouteProviderInterface $route_provider
* The route provider. * The route provider.
......
...@@ -70,7 +70,7 @@ class EmailAction extends ConfigurableActionBase implements ContainerFactoryPlug ...@@ -70,7 +70,7 @@ class EmailAction extends ConfigurableActionBase implements ContainerFactoryPlug
protected $emailValidator; protected $emailValidator;
/** /**
* Constructs a EmailAction object. * Constructs an EmailAction object.
* *
* @param array $configuration * @param array $configuration
* A configuration array containing information about the plugin instance. * A configuration array containing information about the plugin instance.
......
...@@ -21,7 +21,7 @@ abstract class EntityActionBase extends ActionBase implements DependentPluginInt ...@@ -21,7 +21,7 @@ abstract class EntityActionBase extends ActionBase implements DependentPluginInt
protected $entityTypeManager; protected $entityTypeManager;
/** /**
* Constructs a EntityActionBase object. * Constructs an EntityActionBase object.
* *
* @param mixed[] $configuration * @param mixed[] $configuration
* A configuration array containing information about the plugin instance. * A configuration array containing information about the plugin instance.
......
...@@ -71,7 +71,7 @@ class AjaxResponseAttachmentsProcessor implements AttachmentsResponseProcessorIn ...@@ -71,7 +71,7 @@ class AjaxResponseAttachmentsProcessor implements AttachmentsResponseProcessorIn
protected $moduleHandler; protected $moduleHandler;
/** /**
* Constructs a AjaxResponseAttachmentsProcessor object. * Constructs an AjaxResponseAttachmentsProcessor object.
* *
* @param \Drupal\Core\Asset\AssetResolverInterface $asset_resolver * @param \Drupal\Core\Asset\AssetResolverInterface $asset_resolver
* An asset resolver. * An asset resolver.
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
namespace Drupal\Core\Ajax; namespace Drupal\Core\Ajax;
/** /**
* Defines an AJAX command to open content in a dialog in a off-canvas dialog. * Defines an AJAX command to open content in a dialog in an off-canvas tray.
* *
* @ingroup ajax * @ingroup ajax
*/ */
...@@ -18,7 +18,7 @@ class OpenOffCanvasDialogCommand extends OpenDialogCommand { ...@@ -18,7 +18,7 @@ class OpenOffCanvasDialogCommand extends OpenDialogCommand {
* Constructs an OpenOffCanvasDialogCommand object. * Constructs an OpenOffCanvasDialogCommand object.
* *
* The off-canvas dialog differs from the normal modal provided by * The off-canvas dialog differs from the normal modal provided by
* OpenDialogCommand in that a off-canvas has built in positioning and * OpenDialogCommand in that an off-canvas has built in positioning and
* behaviors. Drupal provides a built-in off-canvas dialog for this purpose, * behaviors. Drupal provides a built-in off-canvas dialog for this purpose,
* so the selector is hard-coded in the call to the parent constructor. * so the selector is hard-coded in the call to the parent constructor.
* *
......
...@@ -34,7 +34,7 @@ class UpdateBuildIdCommand implements CommandInterface { ...@@ -34,7 +34,7 @@ class UpdateBuildIdCommand implements CommandInterface {
protected $new; protected $new;
/** /**
* Constructs a UpdateBuildIdCommand object. * Constructs an UpdateBuildIdCommand object.
* *
* @param string $old * @param string $old
* The old build_id. * The old build_id.
......
...@@ -25,7 +25,7 @@ class ArchiverManager extends DefaultPluginManager { ...@@ -25,7 +25,7 @@ class ArchiverManager extends DefaultPluginManager {
protected $fileSystem; protected $fileSystem;
/** /**
* Constructs a ArchiverManager object. * Constructs an ArchiverManager object.
* *
* @param \Traversable $namespaces * @param \Traversable $namespaces
* An object that implements \Traversable which contains the root paths * An object that implements \Traversable which contains the root paths
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
namespace Drupal\Core\Archiver; namespace Drupal\Core\Archiver;
/** /**
* Defines a archiver implementation for .tar files. * Defines an archiver implementation for .tar files.
*/ */
class Tar implements ArchiverInterface { class Tar implements ArchiverInterface {
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
namespace Drupal\Core\Archiver; namespace Drupal\Core\Archiver;
/** /**
* Defines a archiver implementation for .zip files. * Defines an archiver implementation for .zip files.
* *
* @link http://php.net/zip * @link http://php.net/zip
*/ */
......
...@@ -16,7 +16,7 @@ interface AssetDumperInterface { ...@@ -16,7 +16,7 @@ interface AssetDumperInterface {
* The file extension of this asset. * The file extension of this asset.
* *
* @return string * @return string
* An URI to access the dumped asset. * A URI to access the dumped asset.
*/ */
public function dump($data, $file_extension); public function dump($data, $file_extension);
......
...@@ -21,7 +21,7 @@ interface ConfigFactoryInterface { ...@@ -21,7 +21,7 @@ interface ConfigFactoryInterface {
public function get($name); public function get($name);
/** /**
* Returns an mutable configuration object for a given name. * Returns a mutable configuration object for a given name.
* *
* Should not be used for config that will have runtime effects. Therefore it * Should not be used for config that will have runtime effects. Therefore it
* is always loaded override free. * is always loaded override free.
......
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
* *
* @see \Drupal\Core\Config\StorageComparerInterface * @see \Drupal\Core\Config\StorageComparerInterface
* *
* The ConfigImporter has a identifier which is used to construct event names. * The ConfigImporter has an identifier which is used to construct event names.
* The events fired during an import are: * The events fired during an import are:
* - ConfigEvents::IMPORT_VALIDATE: Events listening can throw a * - ConfigEvents::IMPORT_VALIDATE: Events listening can throw a
* \Drupal\Core\Config\ConfigImporterException to prevent an import from * \Drupal\Core\Config\ConfigImporterException to prevent an import from
...@@ -1039,7 +1039,7 @@ protected function importInvokeRename($collection, $rename_name) { ...@@ -1039,7 +1039,7 @@ protected function importInvokeRename($collection, $rename_name) {
} }
/** /**
* Determines if a import is already running. * Determines if an import is already running.
* *
* @return bool * @return bool
* TRUE if an import is already running, FALSE if not. * TRUE if an import is already running, FALSE if not.
......
...@@ -59,7 +59,7 @@ public function __construct(EntityTypeInterface $entity_type, $conjunction, Conf ...@@ -59,7 +59,7 @@ public function __construct(EntityTypeInterface $entity_type, $conjunction, Conf
* Overrides \Drupal\Core\Entity\Query\QueryBase::condition(). * Overrides \Drupal\Core\Entity\Query\QueryBase::condition().
* *
* Additional to the syntax defined in the QueryInterface you can use * Additional to the syntax defined in the QueryInterface you can use
* placeholders (*) to match all keys of an subarray. Let's take the follow * placeholders (*) to match all keys of a subarray. Let's take the follow
* yaml file as example: * yaml file as example:
* @code * @code
* level1: * level1:
......
...@@ -1722,7 +1722,7 @@ public function commit() { ...@@ -1722,7 +1722,7 @@ public function commit() {
} }
/** /**
* Retrieves an unique ID from a given sequence. * Retrieves a unique ID from a given sequence.
* *
* Use this function if for some reason you can't use a serial field. For * Use this function if for some reason you can't use a serial field. For
* example, MySQL has no ways of reading of the current value of a sequence * example, MySQL has no ways of reading of the current value of a sequence
......
...@@ -38,7 +38,7 @@ abstract class Database { ...@@ -38,7 +38,7 @@ abstract class Database {
const RETURN_INSERT_ID = 3; const RETURN_INSERT_ID = 3;
/** /**
* An nested array of all active connections. It is keyed by database name * A nested array of all active connections. It is keyed by database name
* and target. * and target.
* *
* @var array * @var array
......
...@@ -319,7 +319,7 @@ public function getFullQualifiedTableName($table) { ...@@ -319,7 +319,7 @@ public function getFullQualifiedTableName($table) {
} }
/** /**
* Add a new savepoint with an unique name. * Add a new savepoint with a unique name.
* *
* The main use for this method is to mimic InnoDB functionality, which * The main use for this method is to mimic InnoDB functionality, which
* provides an inherent savepoint before any query in a transaction. * provides an inherent savepoint before any query in a transaction.
......
...@@ -99,7 +99,7 @@ public function orderBy($field, $direction = 'ASC') { ...@@ -99,7 +99,7 @@ public function orderBy($field, $direction = 'ASC') {
} }
} }
// If $field contains an characters which are not allowed in a field name // If $field contains characters which are not allowed in a field name
// it is considered an expression, these can't be handled automatically // it is considered an expression, these can't be handled automatically
// either. // either.
if ($this->connection->escapeField($field) != $field) { if ($this->connection->escapeField($field) != $field) {
......
...@@ -366,7 +366,7 @@ public function addField($table, $field, $specification, $keys_new = []) { ...@@ -366,7 +366,7 @@ public function addField($table, $field, $specification, $keys_new = []) {
// Build the mapping between the old fields and the new fields. // Build the mapping between the old fields and the new fields.
$mapping = []; $mapping = [];
if (isset($specification['initial_from_field'])) { if (isset($specification['initial_from_field'])) {
// If we have a initial value, copy it over. // If we have an initial value, copy it over.
if (isset($specification['initial'])) { if (isset($specification['initial'])) {
$expression = 'COALESCE(' . $specification['initial_from_field'] . ', :default_initial_value)'; $expression = 'COALESCE(' . $specification['initial_from_field'] . ', :default_initial_value)';
$arguments = [':default_initial_value' => $specification['initial']]; $arguments = [':default_initial_value' => $specification['initial']];
...@@ -381,7 +381,7 @@ public function addField($table, $field, $specification, $keys_new = []) { ...@@ -381,7 +381,7 @@ public function addField($table, $field, $specification, $keys_new = []) {
]; ];
} }
elseif (isset($specification['initial'])) { elseif (isset($specification['initial'])) {
// If we have a initial value, copy it over. // If we have an initial value, copy it over.
$mapping[$field] = [ $mapping[$field] = [
'expression' => ':newfieldinitial', 'expression' => ':newfieldinitial',
'arguments' => [':newfieldinitial' => $specification['initial']], 'arguments' => [':newfieldinitial' => $specification['initial']],
......
...@@ -48,10 +48,10 @@ interface ConditionInterface { ...@@ -48,10 +48,10 @@ interface ConditionInterface {
* The value to test the field against. In most cases, and depending on the * The value to test the field against. In most cases, and depending on the
* operator, this will be a scalar or an array. As SQL accepts select * operator, this will be a scalar or an array. As SQL accepts select
* queries on any place where a scalar value or set is expected, $value may * queries on any place where a scalar value or set is expected, $value may
* also be a(n array of) SelectInterface(s). If $operator is a unary * also be a SelectInterface or an array of SelectInterfaces. If $operator
* operator, e.g. IS NULL, $value will be ignored and should be null. If * is a unary operator, e.g. IS NULL, $value will be ignored and should be
* the operator requires a subquery, e.g. EXISTS, the $field will be ignored * null. If the operator requires a subquery, e.g. EXISTS, the $field will
* and $value should be a SelectInterface object. * be ignored and $value should be a SelectInterface object.
* @param string|null $operator * @param string|null $operator
* The operator to use. Supported for all supported databases are at least: * The operator to use. Supported for all supported databases are at least:
* - The comparison operators =, <>, <, <=, >, >=. * - The comparison operators =, <>, <, <=, >, >=.
......
...@@ -432,7 +432,7 @@ function hook_query_alter(Drupal\Core\Database\Query\AlterableInterface $query) ...@@ -432,7 +432,7 @@ function hook_query_alter(Drupal\Core\Database\Query\AlterableInterface $query)
* a listing (e.g., from Views) and therefore require access control. * a listing (e.g., from Views) and therefore require access control.
* *
* @param $query * @param $query
* An Query object describing the composite parts of a SQL query. * A Query object describing the composite parts of a SQL query.
* *
* @see hook_query_alter() * @see hook_query_alter()
* @see node_query_node_access_alter() * @see node_query_node_access_alter()
......
...@@ -154,7 +154,7 @@ public static function valueCallback(&$element, $input, FormStateInterface $form ...@@ -154,7 +154,7 @@ public static function valueCallback(&$element, $input, FormStateInterface $form
* element, no other format will work. See the * element, no other format will work. See the
* DateFormatterInterface::format() function for a list of the possible * DateFormatterInterface::format() function for a list of the possible
* formats and HTML5 standards for the HTML5 requirements. Defaults to the * formats and HTML5 standards for the HTML5 requirements. Defaults to the
* right HTML5 format for the chosen element if a HTML5 element is used, * right HTML5 format for the chosen element if an HTML5 element is used,
* otherwise defaults to DateFormat::load('html_date')->getPattern(). * otherwise defaults to DateFormat::load('html_date')->getPattern().
* - #date_date_element: The date element. Options are: * - #date_date_element: The date element. Options are:
* - datetime: Use the HTML5 datetime element type. * - datetime: Use the HTML5 datetime element type.
...@@ -164,7 +164,7 @@ public static function valueCallback(&$element, $input, FormStateInterface $form ...@@ -164,7 +164,7 @@ public static function valueCallback(&$element, $input, FormStateInterface $form
* - none: Do not display a date element. * - none: Do not display a date element.
* - #date_date_callbacks: Array of optional callbacks for the date element. * - #date_date_callbacks: Array of optional callbacks for the date element.
* - #date_time_element: The time element. Options are: * - #date_time_element: The time element. Options are:
* - time: Use a HTML5 time element type. * - time: Use an HTML5 time element type.
* - text: No HTML5 element, use a normal text field. * - text: No HTML5 element, use a normal text field.
* - none: Do not display a time element. * - none: Do not display a time element.
* - #date_time_format: A date format string that describes the format that * - #date_time_format: A date format string that describes the format that
...@@ -173,7 +173,7 @@ public static function valueCallback(&$element, $input, FormStateInterface $form ...@@ -173,7 +173,7 @@ public static function valueCallback(&$element, $input, FormStateInterface $form
* element, no other format will work. See the * element, no other format will work. See the
* DateFormatterInterface::format() function for a list of the possible * DateFormatterInterface::format() function for a list of the possible
* formats and HTML5 standards for the HTML5 requirements. Defaults to the * formats and HTML5 standards for the HTML5 requirements. Defaults to the
* right HTML5 format for the chosen element if a HTML5 element is used, * right HTML5 format for the chosen element if an HTML5 element is used,
* otherwise defaults to DateFormat::load('html_time')->getPattern(). * otherwise defaults to DateFormat::load('html_time')->getPattern().
* - #date_time_callbacks: An array of optional callbacks for the time * - #date_time_callbacks: An array of optional callbacks for the time
* element. Can be used to add a jQuery timepicker or an 'All day' checkbox. * element. Can be used to add a jQuery timepicker or an 'All day' checkbox.
...@@ -394,7 +394,7 @@ public static function formatExample($format) { ...@@ -394,7 +394,7 @@ public static function formatExample($format) {
} }
/** /**
* Retrieves the right format for a HTML5 date element. * Retrieves the right format for an HTML5 date element.
* *
* The format is important because these elements will not work with any other * The format is important because these elements will not work with any other
* format. * format.
...@@ -404,7 +404,7 @@ public static function formatExample($format) { ...@@ -404,7 +404,7 @@ public static function formatExample($format) {
* *
* @return string * @return string
* Returns the right format for the date element, or the original format * Returns the right format for the date element, or the original format
* if this is not a HTML5 element. * if this is not an HTML5 element.
*/ */
protected static function getHtml5DateFormat($element) { protected static function getHtml5DateFormat($element) {
switch ($element['#date_date_element']) { switch ($element['#date_date_element']) {
...@@ -421,7 +421,7 @@ protected static function getHtml5DateFormat($element) { ...@@ -421,7 +421,7 @@ protected static function getHtml5DateFormat($element) {
} }
/** /**
* Retrieves the right format for a HTML5 time element. * Retrieves the right format for an HTML5 time element.
* *
* The format is important because these elements will not work with any other * The format is important because these elements will not work with any other
* format. * format.
...@@ -431,7 +431,7 @@ protected static function getHtml5DateFormat($element) { ...@@ -431,7 +431,7 @@ protected static function getHtml5DateFormat($element) {
* *
* @return string * @return string