| Conditions | 10 |
| Paths | 2 |
| Total Lines | 22 |
| Code Lines | 17 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
Small methods make your code easier to understand, in particular if combined with a good name. Besides, if your method is small, finding a good name is usually much easier.
For example, if you find yourself adding comments to a method's body, this is usually a good sign to extract the commented part to a new method, and use the comment as a starting point when coming up with a good name for this new method.
Commonly applied refactorings include:
If many parameters/temporary variables are present:
| 1 | <?php |
||
| 105 | private function testConfigurations(){ |
||
| 106 | $test = new Testing(); |
||
| 107 | $res = $test->testConfig(); |
||
| 108 | |||
| 109 | $table = new Table($this->output); |
||
| 110 | $this->line('<fg=cyan>Testing Config:'); |
||
| 111 | $table->setRows([ |
||
| 112 | ['<fg=default>login_attemps',isset($res['login_attemps']) ? $res['login_attemps']:"<fg=red>Not Found"], |
||
| 113 | ['<fg=default>logging',isset($res['logging']) ? $res['logging']:"<fg=red>Not Found"], |
||
| 114 | ['<fg=default>input_name',isset($res['input_name']) ? $res['input_name']:"<fg=red>Not Found"], |
||
| 115 | ['<fg=default>redirect_url',isset($res['redirect_url']) ? $res['redirect_url']:"<fg=red>Not Found"], |
||
| 116 | ['<fg=default>protected_action_path',isset($res['protected_action_path']) ? $res['protected_action_path']:"<fg=red>Not Found"], |
||
| 117 | ['<fg=default>protected_middleware_group',isset($res['protected_middleware_group']) ? $res['protected_middleware_group']:"<fg=red>Not Found"], |
||
| 118 | ['<fg=default>message_name',isset($res['message_name']) ? $res['message_name']:"<fg=red>Not Found"], |
||
| 119 | |||
| 120 | ]); |
||
| 121 | $table->render(); |
||
| 122 | |||
| 123 | if($res['err'] > 0 AND !empty($res['file'])){ |
||
| 124 | $this->line('<fg=red>Testing config failed, testing is canceled.'); |
||
| 125 | $this->line($res['file']); |
||
| 126 | exit(); |
||
| 127 | } |
||
| 133 |
The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g.
excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths