lib/Style/Normalizer/TextAlign.php
Avoid unused parameters such as '$ruleName'. Open
Open
public function normalize($ruleValue, string $ruleName = ''): array
- Read upRead up
- Exclude checks
UnusedFormalParameter
Since: 0.2
Avoid passing parameters to methods or constructors and then not using those parameters.
Example
class Foo
{
private function bar($howdy)
{
// $howdy is not used
}
}
Source https://phpmd.org/rules/unusedcode.html#unusedformalparameter
Spaces must be used to indent lines; tabs are not allowed Open
Open
}
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
}
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
return $this->normalized = ['text-align' => $ruleValue];
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
{
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
if (\in_array($ruleValue, ['left', 'right', 'center'])) {
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
if (null === $this->normalized) {
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
return $this->normalized = ['text-align' => 'left'];
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
return $this->normalized;
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
public function normalize($ruleValue, string $ruleName = ''): array
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
}
- Exclude checks