Skip to content

Commit a5d4f7a

Browse files
authored
Merge pull request #8709 from Pebryan354/Pebryan354/update-return-type
docs: fix return type in BaseResult
2 parents 2a3794a + d6347e6 commit a5d4f7a

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

system/Database/BaseResult.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -260,8 +260,8 @@ public function getResultObject(): array
260260
* @param string $type The type of result object. 'array', 'object' or class name.
261261
* @phpstan-param class-string<T>|'array'|'object' $type
262262
*
263-
* @return array|object|stdClass|null
264-
* @phpstan-return ($type is 'object' ? stdClass|null : ($type is 'array' ? array|null : T|null))
263+
* @return array|float|int|object|stdClass|string|null
264+
* @phpstan-return ($n is string ? float|int|string|null : ($type is 'object' ? stdClass|null : ($type is 'array' ? array|null : T|null)))
265265
*/
266266
public function getRow($n = 0, string $type = 'object')
267267
{

system/Database/ResultInterface.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,8 +63,8 @@ public function getResultObject(): array;
6363
* @param string $type The type of result object. 'array', 'object' or class name.
6464
* @phpstan-param class-string<T>|'array'|'object' $type
6565
*
66-
* @return array|object|stdClass|null
67-
* @phpstan-return ($type is 'object' ? stdClass|null : ($type is 'array' ? array|null : T|null))
66+
* @return array|float|int|object|stdClass|string|null
67+
* @phpstan-return ($n is string ? float|int|string|null : ($type is 'object' ? stdClass|null : ($type is 'array' ? array|null : T|null)))
6868
*/
6969
public function getRow($n = 0, string $type = 'object');
7070

0 commit comments

Comments
 (0)