Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit cb896d6

Browse files
committedOct 18, 2024··
Fix CS
1 parent 5453e62 commit cb896d6

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed
 

‎src/Illuminate/Database/Query/Grammars/Grammar.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1139,7 +1139,7 @@ protected function wrapUnion($sql)
11391139
protected function compileUnionAggregate(Builder $query)
11401140
{
11411141
$sql = $this->compileAggregate($query, $query->aggregate);
1142-
$group = $query->groups ? ' ' . $this->compileGroups($query, $query->groups) : '';
1142+
$group = $query->groups ? ' '.$this->compileGroups($query, $query->groups) : '';
11431143

11441144
$query->aggregate = null;
11451145
$query->groups = null;

‎tests/Database/DatabaseQueryBuilderTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1809,7 +1809,7 @@ public function testGroupByAndAggregate()
18091809
{
18101810
$builder = $this->getBuilder();
18111811

1812-
$queryResults = [(object) ['aggregate' => 2, 'role' => 'admin', 'city' => 'NY'], (object) ['aggregate' => 5, 'role' => 'user', 'city' => 'LA']];
1812+
$queryResults = [['aggregate' => 2, 'role' => 'admin', 'city' => 'NY'], ['aggregate' => 5, 'role' => 'user', 'city' => 'LA']];
18131813
$builder->getConnection()
18141814
->shouldReceive('select')->once()
18151815
->with('select "role", "city", count(*) as aggregate from "users" group by "role", "city"', [], true)
@@ -1823,7 +1823,7 @@ public function testGroupByUnionAndAggregate()
18231823
{
18241824
$builder = $this->getBuilder();
18251825

1826-
$queryResults = [(object) ['aggregate' => 2, 'role' => 'admin', 'city' => 'NY'], (object) ['aggregate' => 5, 'role' => 'user', 'city' => 'LA']];
1826+
$queryResults = [['aggregate' => 2, 'role' => 'admin'], ['aggregate' => 5, 'role' => 'user', ]];
18271827
$builder->getConnection()
18281828
->shouldReceive('select')->once()
18291829
->with('select "role", count(*) as aggregate from ((select * from "users") union (select * from "members")) as "temp_table" group by "role"', [], true)

0 commit comments

Comments
 (0)
Please sign in to comment.