| Conditions | 1 |
| Paths | 1 |
| Total Lines | 80 |
| Code Lines | 37 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 1 |
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 |
||
| 103 | public static function provideFixGenericWikiSyntax(): array |
||
| 104 | { |
||
| 105 | return [ |
||
| 106 | [ |
||
| 107 | <<<EOF |
||
| 108 | {{Infobox}} |
||
| 109 | Blab <ref name="A">fu</ref> |
||
| 110 | <ref name="B">fu</ref>. |
||
| 111 | bzear |
||
| 112 | {{Références |taille=3 |références= |
||
| 113 | |||
| 114 | <ref name="C">fu</ref> |
||
| 115 | <ref name="D">fu</ref> <ref name="E">fu</ref> |
||
| 116 | }} |
||
| 117 | EOF, |
||
| 118 | <<<EOF |
||
| 119 | {{Infobox}} |
||
| 120 | Blab<ref name="A">fu</ref>{{,}}<ref name="B">fu</ref>. |
||
| 121 | bzear |
||
| 122 | {{Références |taille=3 |références= |
||
| 123 | |||
| 124 | <ref name="C">fu</ref> |
||
| 125 | <ref name="D">fu</ref> <ref name="E">fu</ref> |
||
| 126 | }} |
||
| 127 | EOF |
||
| 128 | , |
||
| 129 | ], |
||
| 130 | [ |
||
| 131 | <<<EOF |
||
| 132 | {{Infobox}} |
||
| 133 | Blab <ref name="A">fu</ref> |
||
| 134 | <ref name="B">fu</ref>. |
||
| 135 | bzear |
||
| 136 | {{Références nombreuses |taille=3 |références= |
||
| 137 | <ref name="C">fu</ref> |
||
| 138 | <ref name="D">fu</ref> |
||
| 139 | }} |
||
| 140 | EOF, |
||
| 141 | <<<EOF |
||
| 142 | {{Infobox}} |
||
| 143 | Blab<ref name="A">fu</ref>{{,}}<ref name="B">fu</ref>. |
||
| 144 | bzear |
||
| 145 | {{Références nombreuses |taille=3 |références= |
||
| 146 | <ref name="C">fu</ref> |
||
| 147 | <ref name="D">fu</ref> |
||
| 148 | }} |
||
| 149 | EOF, |
||
| 150 | ], |
||
| 151 | [ |
||
| 152 | <<<EOF |
||
| 153 | {{Infobox}} |
||
| 154 | Blab <ref name="A">fu</ref> |
||
| 155 | <ref name="B">fu</ref>. |
||
| 156 | bzear |
||
| 157 | {{Références nombreuses |taille=3 |références= |
||
| 158 | <ref name="C">fu</ref> |
||
| 159 | <ref name="D">fu</ref> |
||
| 160 | }} |
||
| 161 | EOF, |
||
| 162 | <<<EOF |
||
| 163 | {{Infobox}} |
||
| 164 | Blab<ref name="A">fu</ref>{{,}}<ref name="B">fu</ref>. |
||
| 165 | bzear |
||
| 166 | {{Références nombreuses |taille=3 |références= |
||
| 167 | <ref name="C">fu</ref> |
||
| 168 | <ref name="D">fu</ref> |
||
| 169 | }} |
||
| 170 | EOF, |
||
| 171 | ], |
||
| 172 | [ |
||
| 173 | "le ''Paso de l'[[abrivado]]'', spécialement composé par [[Eddie Vartan]] |
||
| 174 | |||
| 175 | == Notes et références == |
||
| 176 | {{Références|groupe=Note|colonnes=2}} |
||
| 177 | {{Références|références= |
||
| 178 | <ref name=ATP> |
||
| 179 | {{Pdf}}{{Lien web|url=http://www.sports.gouv.fr/IMG/pdf/atlas.pdf|titre=Atlas national des fédérations sportives 2012.|site=www.sports.gouv.fr|consulté le=05 mars 2015}} |
||
| 180 | .</ref> |
||
| 181 | |colonnes=2}}", |
||
| 182 | "le ''Paso de l'[[abrivado]]'', spécialement composé par [[Eddie Vartan]] |
||
| 183 | |||
| 219 |