Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix coding standards. #508

Merged
merged 1 commit into from
Sep 20, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
"phpspec/phpspec": "~2.0 || ~4.0",
"behat/mink-zombie-driver": "^1.2",
"jakub-onderka/php-parallel-lint": "^0.9.2",
"drupal/coder": "^8.2"
"drupal/coder": "~8.2.12"
},
"scripts": {
"test": [
Expand Down
18 changes: 9 additions & 9 deletions src/Drupal/DrupalExtension/Context/RawDrupalContext.php
Original file line number Diff line number Diff line change
Expand Up @@ -404,17 +404,17 @@ public function parseEntityFields($entity_type, \stdClass $entity)
// Reset the multicolumn field if the field name does not contain a column.
if (strpos($field, ':') === false) {
$multicolumn_field = '';
} // Start tracking a new multicolumn field if the field name contains a ':'
// which is preceded by at least 1 character.
elseif (strpos($field, ':', 1) !== false) {
} elseif (strpos($field, ':', 1) !== false) {
// Start tracking a new multicolumn field if the field name contains a ':'
// which is preceded by at least 1 character.
list($multicolumn_field, $multicolumn_column) = explode(':', $field);
} // If a field name starts with a ':' but we are not yet tracking a
// multicolumn field we don't know to which field this belongs.
elseif (empty($multicolumn_field)) {
} elseif (empty($multicolumn_field)) {
// If a field name starts with a ':' but we are not yet tracking a
// multicolumn field we don't know to which field this belongs.
throw new \Exception('Field name missing for ' . $field);
} // Update the column name if the field name starts with a ':' and we are
// already tracking a multicolumn field.
else {
} else {
// Update the column name if the field name starts with a ':' and we are
// already tracking a multicolumn field.
$multicolumn_column = substr($field, 1);
}

Expand Down