Skip to content

Commit

Permalink
CS fix
Browse files Browse the repository at this point in the history
  • Loading branch information
bytehead committed Jan 12, 2022
1 parent d60e29f commit 6bbe3f3
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ public function optionsCallback(DataContainer $dc): array
$modules = $result->fetchAllAssociative();

foreach ($modules as $module) {
if ($hasTypes && !in_array($module['type'], $types, true)) {
if ($hasTypes && !\in_array($module['type'], $types, true)) {
continue;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -286,7 +286,8 @@ public function testReturnsAllTypesOfModulesAsOption(): void
'contao_csrf_token'
);

$this->assertSame([
$this->assertSame(
[
10 => 'name-10',
20 => 'name-20',
30 => 'name-30',
Expand All @@ -303,9 +304,9 @@ public function testReturnsSelectedTypesOfModulesAsOption(): void
'modules' => [
'foo',
'bar',
]
]
]
],
],
],
]);

$dataContainer = $this->mockClassWithProperties(DataContainer::class);
Expand All @@ -325,10 +326,11 @@ public function testReturnsSelectedTypesOfModulesAsOption(): void
'contao_csrf_token'
);

$this->assertSame([
10 => 'name-10',
20 => 'name-20',
],
$this->assertSame(
[
10 => 'name-10',
20 => 'name-20',
],
$listener->optionsCallback($dataContainer)
);
}
Expand Down

0 comments on commit 6bbe3f3

Please sign in to comment.