Skip to content

Commit cd3ae2c

Browse files
committed
return early on force_all_routes is truthy
1 parent c0a3996 commit cd3ae2c

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

src/HttpsTrait.php

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -39,13 +39,12 @@ private function isGoingToBeForcedToHttps($match = null) : bool
3939
return $this->config['allow_404'];
4040
}
4141

42+
if ($this->config['force_all_routes']) {
43+
return true;
44+
}
45+
4246
Assert::notNull($match);
43-
if (! $this->config['force_all_routes'] &&
44-
! \in_array(
45-
$match->getMatchedRouteName(),
46-
$this->config['force_specific_routes']
47-
)
48-
) {
47+
if (! \in_array($match->getMatchedRouteName(), $this->config['force_specific_routes'])) {
4948
return false;
5049
}
5150

0 commit comments

Comments
 (0)