Skip to content

Commit

Permalink
Apply fixes from StyleCI
Browse files Browse the repository at this point in the history
  • Loading branch information
K-Phoen authored and StyleCIBot committed Jul 21, 2018
1 parent 13354af commit 0a3980b
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 5 deletions.
3 changes: 1 addition & 2 deletions src/Boucle.php
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ public function end(): Step
throw new \LogicException('Could not get the end of the boucle: no steps registered');
}

return $this->steps[count($this->steps)-1];
return $this->steps[count($this->steps) - 1];
}

public function startBy(): Transport
Expand Down Expand Up @@ -103,7 +103,6 @@ public function steps(): iterable
*
* @TODO refactor
*/

public function hasStep(int $i): bool
{
return isset($this->steps[$i]);
Expand Down
4 changes: 2 additions & 2 deletions src/Compiler/BoucleToJson.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,10 @@ public function compile(Boucle $boucle, string $webRoot): void
];

foreach ($boucle->steps() as $i => $step) {
if (!$boucle->hasStep($i+1)) {
if (!$boucle->hasStep($i + 1)) {
$departureDate = '';
} else {
$departureDate = $boucle->step($i+1)->date()->format('Y-m-d');
$departureDate = $boucle->step($i + 1)->date()->format('Y-m-d');
}

$data['steps'][(string) $step->transport()][] = [
Expand Down
2 changes: 1 addition & 1 deletion src/Config/UnknownLocation.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

class UnknownLocation extends \RuntimeException
{
public static function fromName(string $name, \Exception $previous = null): UnknownLocation
public static function fromName(string $name, \Exception $previous = null): self
{
return new static(sprintf('Unknown location "%s"', $name), 0, $previous);
}
Expand Down

0 comments on commit 0a3980b

Please sign in to comment.