Conditions | 2 |
Paths | 2 |
Total Lines | 13 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php declare(strict_types=1); |
||
38 | protected function execute(InputInterface $input, OutputInterface $output) |
||
39 | { |
||
40 | $url = $input->getArgument('url'); |
||
41 | $output->writeln("<info>Discovering feeds from {$url}</info>"); |
||
42 | $feedIo = Factory::create()->getFeedIo(); |
||
43 | $feeds = $feedIo->discover($url); |
||
|
|||
44 | |||
45 | foreach ($feeds as $feed) { |
||
46 | $output->writeln("<info>found : {$feed}</info>"); |
||
47 | } |
||
48 | |||
49 | return 0; |
||
50 | } |
||
51 | } |
||
52 |
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.