Skip to content

Commit a67ee68

Browse files
committed
docs: add @var for PHPStan
1 parent 5f4a906 commit a67ee68

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

app/Controllers/DungeonController.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
namespace App\Controllers;
44

5+
use App\Entities\Dungeon;
56
use App\Models\DungeonModel;
67
use CodeIgniter\HTTP\ResponseInterface;
78

@@ -33,6 +34,7 @@ public function __construct()
3334
*/
3435
public function show(int $id)
3536
{
37+
/** @var Dungeon|null $dungeon */
3638
$dungeon = $this->dungeons->find($id);
3739

3840
if ($dungeon === null) {

tests/database/FakerTest.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@ public function testCreateAddsToDatabase()
6464
public function testHelperUsesFaker()
6565
{
6666
// test_helper comes with the fake() method that does the same as above without all the set up
67+
/** @var Monster $monster */
6768
$monster = fake(MonsterFaker::class);
6869
$this->assertIsInt($monster->id);
6970

0 commit comments

Comments
 (0)