Total Complexity | 5 |
Total Lines | 33 |
Duplicated Lines | 0 % |
Coverage | 0% |
Changes | 0 |
1 | <?php |
||
12 | abstract class PostTypeRegistrationModule extends Module implements ModuleInterface |
||
13 | { |
||
14 | use TargetsInitHook; |
||
15 | |||
16 | public function hook(): void |
||
17 | { |
||
18 | $this->targetInitHook(); |
||
19 | } |
||
20 | |||
21 | protected function doInitAction(): void |
||
22 | { |
||
23 | $this->registerPostTypes(); |
||
24 | } |
||
25 | |||
26 | protected function registerPostTypes(): void |
||
29 | } |
||
30 | |||
31 | protected function postTypeRegistrar(): PostTypeRegistrarInterface |
||
34 | } |
||
35 | |||
36 | protected function optionHandlers(): ?PostTypeOptionHandlerCollectionInterface |
||
39 | } |
||
40 | |||
41 | /** |
||
42 | * @return PostTypeInterface[] |
||
43 | */ |
||
44 | abstract protected function postTypes(): array; |
||
45 | } |
||
46 |
This check looks for function or method calls that always return null and whose return value is used.
The method
getObject()
can return nothing but null, so it makes no sense to use the return value.The reason is most likely that a function or method is imcomplete or has been reduced for debug purposes.