Conditions | 13 |
Paths | 3 |
Total Lines | 27 |
Code Lines | 22 |
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 | ['<fg=default>enable_except_account',isset($res['enable_except_account']) ? $res['enable_except_account']:"<fg=red>Not Found"], |
||
120 | ['<fg=default>except_account',isset($res['except_account']) ? $res['except_account']:"<fg=red>Not Found"], |
||
121 | |||
122 | ]); |
||
123 | $table->render(); |
||
124 | if($res['err'] > 0){ |
||
125 | $this->line('<fg=red>Config invalid, testing is canceled.'); |
||
126 | exit(); |
||
127 | } |
||
128 | if($res['err'] > 0 AND !empty($res['file'])){ |
||
129 | $this->line('<fg=red>Testing config failed, testing is canceled.'); |
||
130 | $this->line($res['file']); |
||
131 | exit(); |
||
132 | } |
||
138 |
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