Skip to content

Commit 2d294be

Browse files
authored
Merge pull request #356 from bowphp/refactor/code-base
Fix aggreate result type
2 parents 0dcd64e + 1c49713 commit 2d294be

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/Database/QueryBuilder.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -862,7 +862,7 @@ private function aggregate($aggregate, $column): mixed
862862
}
863863

864864
// Notice: The result of the next action can be float or int type
865-
return $statement->fetchColumn();
865+
return $statement->fetchColumn() ?? 0;
866866
}
867867

868868
/**

0 commit comments

Comments
 (0)