We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
OutputFormatter
1 parent f1f3fba commit 769bfe5Copy full SHA for 769bfe5
src/OutputFormatter.php
@@ -194,13 +194,15 @@ public function removeLastSemicolon(string $string): string
194
if ($this->outputFormat->getSemicolonAfterLastRule()) {
195
return $string;
196
}
197
+
198
$parts = \explode(';', $string);
199
if (\count($parts) < 2) {
200
return $parts[0];
201
- $sLast = \array_pop($parts);
202
- $sNextToLast = \array_pop($parts);
203
- \array_push($parts, $sNextToLast . $sLast);
+ $lastPart = \array_pop($parts);
+ $nextToLastPart = \array_pop($parts);
204
+ \array_push($parts, $nextToLastPart . $lastPart);
205
206
return \implode(';', $parts);
207
208
0 commit comments