| 1 | <?php |
||
| 10 | class CreateSnapshotCommand extends Command |
||
| 11 | { |
||
| 12 | protected $signature = 'event-projector:create-snapshot {projectorName} {--name}'; |
||
| 13 | |||
| 14 | protected $description = 'Create new snapshots'; |
||
| 15 | |||
| 16 | /** @var \Spatie\EventProjector\EventProjectionist */ |
||
| 17 | protected $eventProjectionist; |
||
| 18 | |||
| 19 | /** @var \Spatie\EventProjector\Snapshots\SnapshotFactory */ |
||
| 20 | protected $snapshotFactory; |
||
| 21 | |||
| 22 | public function __construct(EventProjectionist $eventProjectionist, SnapshotFactory $snapshotFactory) |
||
| 30 | |||
| 31 | public function handle() |
||
| 45 | } |
||
| 46 | |||
| 47 |
If a method or function can return multiple different values and unless you are sure that you only can receive a single value in this context, we recommend to add an additional type check:
If this a common case that PHP Analyzer should handle natively, please let us know by opening an issue.