Commit 3a6cac15 authored by alexpott's avatar alexpott

Issue #2572731 by attiks, andypost: Fix 'Drupal.Formatting.SpaceUnaryOperator' coding standard

parent 747be317
...@@ -73,7 +73,7 @@ public function format(Diff $diff) { ...@@ -73,7 +73,7 @@ public function format(Diff $diff) {
$context = $edit->orig; $context = $edit->orig;
} }
else { else {
if (! is_array($block)) { if (!is_array($block)) {
$context = array_slice($context, sizeof($context) - $nlead); $context = array_slice($context, sizeof($context) - $nlead);
$x0 = $xi - sizeof($context); $x0 = $xi - sizeof($context);
$y0 = $yi - sizeof($context); $y0 = $yi - sizeof($context);
......
...@@ -363,7 +363,7 @@ protected function _shift_boundaries($lines, &$changed, $other_changed) { ...@@ -363,7 +363,7 @@ protected function _shift_boundaries($lines, &$changed, $other_changed) {
while ($j < $other_len && $other_changed[$j]) { while ($j < $other_len && $other_changed[$j]) {
$j++; $j++;
} }
while ($i < $len && ! $changed[$i]) { while ($i < $len && !$changed[$i]) {
$this::USE_ASSERTS && assert('$j < $other_len && ! $other_changed[$j]'); $this::USE_ASSERTS && assert('$j < $other_len && ! $other_changed[$j]');
$i++; $i++;
$j++; $j++;
......
...@@ -80,7 +80,7 @@ public function addField($field, $type, $langcode) { ...@@ -80,7 +80,7 @@ public function addField($field, $type, $langcode) {
$entity_type = $this->entityManager->getDefinition($entity_type_id); $entity_type = $this->entityManager->getDefinition($entity_type_id);
$field_storage_definitions = $this->entityManager->getFieldStorageDefinitions($entity_type_id); $field_storage_definitions = $this->entityManager->getFieldStorageDefinitions($entity_type_id);
for ($key = 0; $key <= $count; $key ++) { for ($key = 0; $key <= $count; $key++) {
// This can either be the name of an entity base field or a configurable // This can either be the name of an entity base field or a configurable
// field. // field.
$specifier = $specifiers[$key]; $specifier = $specifiers[$key];
......
...@@ -22,6 +22,7 @@ ...@@ -22,6 +22,7 @@
<rule ref="Drupal.Files.EndFileNewline"/> <rule ref="Drupal.Files.EndFileNewline"/>
<rule ref="Drupal.Files.TxtFileLineLength"/> <rule ref="Drupal.Files.TxtFileLineLength"/>
<rule ref="Drupal.Formatting.SpaceInlineIf"/> <rule ref="Drupal.Formatting.SpaceInlineIf"/>
<rule ref="Drupal.Formatting.SpaceUnaryOperator"/>
<rule ref="Drupal.Functions.DiscouragedFunctions"/> <rule ref="Drupal.Functions.DiscouragedFunctions"/>
<rule ref="Drupal.Functions.FunctionDeclaration.SpaceAfter"/> <rule ref="Drupal.Functions.FunctionDeclaration.SpaceAfter"/>
<rule ref="Drupal.Functions.FunctionDeclaration.SpaceBeforeParenthesis"/> <rule ref="Drupal.Functions.FunctionDeclaration.SpaceBeforeParenthesis"/>
......
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