Skip to content

Commit 7b69bc5

Browse files
committed
Enhancement: Return early
1 parent 1ecacf8 commit 7b69bc5

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

src/Extension.php

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,11 @@ private function resolveMaximumDuration(string $test): Duration
166166
return $this->maximumDuration;
167167
}
168168
}
169-
} elseif ($phpUnitVersion->major()->equals(Version\Major::fromInt(10))) {
169+
170+
return;
171+
}
172+
173+
if ($phpUnitVersion->major()->equals(Version\Major::fromInt(10))) {
170174
/**
171175
* @internal
172176
*/
@@ -215,9 +219,11 @@ public function bootstrap(
215219
);
216220
}
217221
}
218-
} else {
222+
223+
return;
224+
}
225+
219226
throw new \RuntimeException(\sprintf(
220227
'Unable to select extension for PHPUnit version with version identifier "%s".',
221228
Runner\Version::id(),
222229
));
223-
}

0 commit comments

Comments
 (0)