Skip to content

Commit

Permalink
refactor: system/Debug/Toolbar/Collectors/Routes.php
Browse files Browse the repository at this point in the history
  • Loading branch information
mcsaygili committed Apr 10, 2024
1 parent 2c524fd commit 4fa96ba
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 5 deletions.
5 changes: 0 additions & 5 deletions phpstan-baseline.php
Original file line number Diff line number Diff line change
Expand Up @@ -4466,11 +4466,6 @@
'count' => 1,
'path' => __DIR__ . '/system/Debug/Toolbar/Collectors/Logs.php',
];
$ignoreErrors[] = [
'message' => '#^Method CodeIgniter\\\\Debug\\\\Toolbar\\\\Collectors\\\\Routes\\:\\:display\\(\\) return type has no value type specified in iterable type array\\.$#',
'count' => 1,
'path' => __DIR__ . '/system/Debug/Toolbar/Collectors/Routes.php',
];
$ignoreErrors[] = [
'message' => '#^Method CodeIgniter\\\\Debug\\\\Toolbar\\\\Collectors\\\\Timers\\:\\:formatTimelineData\\(\\) return type has no value type specified in iterable type array\\.$#',
'count' => 1,
Expand Down
19 changes: 19 additions & 0 deletions system/Debug/Toolbar/Collectors/Routes.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,25 @@ class Routes extends BaseCollector
/**
* Returns the data of this collector to be formatted in the toolbar
*
* @return array{
* matchedRoute: array<array{
* directory: string,
* controller: string,
* method: string,
* paramCount: int,
* truePCount: int,
* params: array<array{
* name: string,
* value: mixed
* }>
* }>,
* routes: array<array{
* method: string,
* route: string,
* handler: string
* }>
* }
*
* @throws ReflectionException
*/
public function display(): array
Expand Down

0 comments on commit 4fa96ba

Please sign in to comment.