Commit 1f191080 authored by catch's avatar catch

Issue #2902723 by mfernea, ccjjmartin: Fix...

Issue #2902723 by mfernea, ccjjmartin: Fix 'Drupal.Commenting.FunctionComment.ReturnCommentIndentation' coding standard
parent fa6e4b2f
......@@ -326,7 +326,7 @@ public function __call($method, $args) {
* Should the interval be forced to be positive?
*
* @return \DateInterval
* A DateInterval object representing the difference between the two dates.
* A DateInterval object representing the difference between the two dates.
*
* @throws \BadMethodCallException
* If the input isn't a DateTime or DateTimePlus object.
......
......@@ -44,8 +44,8 @@ public function __construct($from_lines, $to_lines) {
*
* $diff = new Diff($lines1, $lines2);
* $rev = $diff->reverse();
* @return object A Diff object representing the inverse of the
* original diff.
* @return object
* A Diff object representing the inverse of the original diff.
*/
public function reverse() {
$rev = $this;
......
......@@ -177,7 +177,7 @@ public function addPage($entity_type_id) {
* The entity type ID.
*
* @return string
* The title for the entity add page.
* The title for the entity add page.
*/
public function addTitle($entity_type_id) {
$entity_type = $this->entityTypeManager->getDefinition($entity_type_id);
......@@ -195,7 +195,7 @@ public function addTitle($entity_type_id) {
* The name of the route parameter that holds the bundle.
*
* @return string
* The title for the entity add page, if the bundle was found.
* The title for the entity add page, if the bundle was found.
*/
public function addBundleTitle(RouteMatchInterface $route_match, $entity_type_id, $bundle_parameter) {
$bundles = $this->entityTypeBundleInfo->getBundleInfo($entity_type_id);
......
......@@ -375,12 +375,11 @@ public function setIconPath($icon) {
* Gets the regions for this layout definition.
*
* @return array[]
* The layout regions. The keys of the array are the machine names of the
* regions, and the values are an associative array with the following
* keys:
* - label: (string) The human-readable name of the region.
* Any remaining keys may have special meaning for the given layout plugin,
* but are undefined here.
* The layout regions. The keys of the array are the machine names of the
* regions, and the values are an associative array with the following keys:
* - label: (string) The human-readable name of the region.
* Any remaining keys may have special meaning for the given layout plugin,
* but are undefined here.
*/
public function getRegions() {
return $this->regions;
......
......@@ -138,11 +138,11 @@ public function __construct(Connection $connection, StateInterface $state, Curre
* @param Request $request
* A request against which to match.
*
* @return \Symfony\Component\Routing\RouteCollection with all urls that
* could potentially match $request. Empty collection if nothing can
* match. The collection will be sorted from highest to lowest fit (match
* of path parts) and then in ascending order by route name for routes
* with the same fit.
* @return \Symfony\Component\Routing\RouteCollection
* RouteCollection with all urls that could potentially match $request.
* Empty collection if nothing can match. The collection will be sorted from
* highest to lowest fit (match of path parts) and then in ascending order
* by route name for routes with the same fit.
*/
public function getRouteCollectionForRequest(Request $request) {
// Cache both the system path as well as route parameters and matching
......
......@@ -560,7 +560,7 @@ public function getTypeId() {
* @see ::baseFieldDefinitions()
*
* @return bool
* TRUE if the comment should be published, FALSE otherwise.
* TRUE if the comment should be published, FALSE otherwise.
*/
public static function getDefaultStatus() {
return \Drupal::currentUser()->hasPermission('skip comment approval') ? CommentInterface::PUBLISHED : CommentInterface::NOT_PUBLISHED;
......
......@@ -229,7 +229,7 @@ public function lookupDestinationId(array $source_id_values);
* If unkeyed, the first count($source_id_values) keys will be assumed.
*
* @return array
* An array of arrays of destination identifier values.
* An array of arrays of destination identifier values.
*
* @throws \Drupal\migrate\MigrateException
* Thrown when $source_id_values contains unknown keys, or is the wrong
......
......@@ -320,7 +320,7 @@ function hook_node_grants_alter(&$grants, \Drupal\Core\Session\AccountInterface
* The user object to perform the access check operation on.
*
* @return \Drupal\Core\Access\AccessResultInterface
* The access result.
* The access result.
*
* @ingroup node_access
*/
......
......@@ -183,7 +183,7 @@ protected function refreshTestStateAfterRestConfigChange() {
* The HTTP method (GET, POST, PATCH, DELETE).
*
* @return string
* The error string.
* The error string.
*/
protected function getExpectedUnauthorizedAccessMessage($method) {
$resource_plugin_id = str_replace('.', ':', static::$resourceConfigId);
......
......@@ -51,7 +51,7 @@ public static function create(ContainerInterface $container, array $configuratio
* Override the behavior of title(). Get the name of the user.
*
* @return array
* A list of usernames.
* A list of usernames.
*/
public function titleQuery() {
return array_map(function($account) {
......
......@@ -223,7 +223,7 @@ public function sanitizeValue($value, $type = NULL) {
* - ucwords: Make each word in the string uppercase.
*
* @return string
* The transformed string.
* The transformed string.
*/
protected function caseTransform($string, $option) {
switch ($option) {
......
......@@ -86,7 +86,7 @@ public function title() {
/**
* Override for specific title lookups.
* @return array
* Returns all titles, if it's just one title it's an array with one entry.
* Returns all titles, if it's just one title it's an array with one entry.
*/
public function titleQuery() {
return $this->value;
......
......@@ -178,7 +178,7 @@ public function submitOptionsForm(&$form, FormStateInterface $form_state) {
* - subquery_order: either ASC or DESC.
*
* @return string
* The subquery SQL string, ready for use in the main query.
* The subquery SQL string, ready for use in the main query.
*/
protected function leftQuery($options) {
// Either load another view, or create one on the fly.
......
......@@ -160,7 +160,7 @@ public function buildSortPost() {
* display has listed due to access control or other changes.
*
* @return array
* An array of all the sanitized columns.
* An array of all the sanitized columns.
*/
public function sanitizeColumns($columns, $fields = NULL) {
$sanitized = [];
......
......@@ -61,7 +61,6 @@
<exclude name="Drupal.Commenting.FunctionComment.ParamMissingDefinition"/>
<exclude name="Drupal.Commenting.FunctionComment.ParamNameNoMatch"/>
<exclude name="Drupal.Commenting.FunctionComment.ParamTypeSpaces"/>
<exclude name="Drupal.Commenting.FunctionComment.ReturnCommentIndentation"/>
<exclude name="Drupal.Commenting.FunctionComment.ReturnTypeSpaces"/>
<exclude name="Drupal.Commenting.FunctionComment.TypeHintMissing"/>
</rule>
......
......@@ -80,7 +80,7 @@ public function testDoesNotConvertControllerResult() {
* The return Object.
*
* @return \Symfony\Component\HttpKernel\Event\GetResponseForControllerResultEvent|\PHPUnit_Framework_MockObject_MockObject
* A mock object to test.
* A mock object to test.
*/
protected function createEventMock($controller_result) {
$event = $this->getMock('Symfony\Component\HttpKernel\Event\GetResponseForControllerResultEvent', [], [], '', NULL);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment