We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents a967b6c + 7855c9e commit c154304Copy full SHA for c154304
src/Builder/RunnableSelect.php
@@ -116,10 +116,12 @@ public function fetchGroups(array $fields) {
116
$tmp = &$result;
117
foreach($fields as $field) {
118
$value = $row[$field];
119
- $tmp[$value] = [];
+ if(!array_key_exists($value, $tmp)) {
120
+ $tmp[$value] = [];
121
+ }
122
$tmp = &$tmp[$value];
123
}
- $tmp = $row;
124
+ $tmp[] = $row;
125
126
return $result;
127
@@ -136,7 +138,7 @@ public function fetchArray() {
136
138
137
139
/**
140
* @param mixed $default
- * @return string[]
141
+ * @return null|bool|string|int|float
142
*/
143
public function fetchValue($default = null) {
144
$statement = $this->createStatement();
0 commit comments