Commit 4005f93b authored by catch's avatar catch

Issue #2901735 by mfernea: Fix 'Squiz.Arrays.ArrayBracketSpacing' coding standard

parent 3bc858ec
......@@ -214,7 +214,7 @@ protected function getFieldInfo($node_type) {
$query->fields('cnf');
foreach ($query->execute() as $field) {
$this->fieldInfo[ $field['type_name'] ][ $field['field_name'] ] = $field;
$this->fieldInfo[$field['type_name']][$field['field_name']] = $field;
}
foreach ($this->fieldInfo as $type => $fields) {
......
......@@ -150,6 +150,7 @@
</rule>
<!-- Squiz sniffs -->
<rule ref="Squiz.Arrays.ArrayBracketSpacing"/>
<rule ref="Squiz.Arrays.ArrayDeclaration">
<exclude name="Squiz.Arrays.ArrayDeclaration.NoKeySpecified"/>
<exclude name="Squiz.Arrays.ArrayDeclaration.KeySpecified"/>
......
......@@ -113,14 +113,14 @@ public function providerTestLog() {
$request_mock->headers = $this->getMock('Symfony\Component\HttpFoundation\ParameterBag');
// No request or account.
$cases [] = [
$cases[] = [
function ($context) {
return $context['channel'] == 'test' && empty($context['uid']) && empty($context['ip']);
},
];
// With account but not request. Since the request is not available the
// current user should not be used.
$cases [] = [
$cases[] = [
function ($context) {
return $context['uid'] === 0 && empty($context['ip']);
},
......@@ -128,14 +128,14 @@ function ($context) {
$account_mock,
];
// With request but not account.
$cases [] = [
$cases[] = [
function ($context) {
return $context['ip'] === '127.0.0.1' && empty($context['uid']);
},
$request_mock,
];
// Both request and account.
$cases [] = [
$cases[] = [
function ($context) {
return $context['ip'] === '127.0.0.1' && $context['uid'] === 1;
},
......
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