| 1 | <?php |
||
| 8 | class CreateClientCommand extends Command |
||
| 9 | { |
||
| 10 | /** |
||
| 11 | * The name and signature of the console command. |
||
| 12 | * |
||
| 13 | * @var string |
||
| 14 | */ |
||
| 15 | protected $signature = 'client:create {name} {type} {status=active}'; |
||
| 16 | |||
| 17 | /** |
||
| 18 | * The console command description. |
||
| 19 | * |
||
| 20 | * @var string |
||
| 21 | */ |
||
| 22 | protected $description = 'Command to create client with API keys'; |
||
| 23 | |||
| 24 | /** |
||
| 25 | * Create a new command instance. |
||
| 26 | * |
||
| 27 | * @return void |
||
| 28 | */ |
||
| 29 | |||
| 30 | /** |
||
| 31 | * The KeyManagerInterface. |
||
| 32 | * |
||
| 33 | * @var KeyManagerInterface |
||
| 34 | */ |
||
| 35 | private $manager; |
||
| 36 | |||
| 37 | /** |
||
| 38 | * @param KeyManagerInterface $manager |
||
| 39 | */ |
||
| 40 | public function __construct(KeyManagerInterface $manager) |
||
| 46 | |||
| 47 | /** |
||
| 48 | * Execute the console command. |
||
| 49 | * |
||
| 50 | * @return void |
||
| 51 | */ |
||
| 52 | public function handle(): void |
||
| 70 | } |
||
| 71 |
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.