Skip to content

Commit

Permalink
Use return null; when the return type is null
Browse files Browse the repository at this point in the history
  • Loading branch information
wouterj committed Sep 15, 2021
1 parent dcf9d89 commit 0e0e862
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/Illuminate/Container/Util.php
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ public static function getParameterClassName($parameter)
$type = $parameter->getType();

if (! $type instanceof ReflectionNamedType || $type->isBuiltin()) {
return;
return null;
}

$name = $type->getName();
Expand Down
2 changes: 1 addition & 1 deletion src/Illuminate/Translation/MessageSelector.php
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ private function extractFromString($part, $number)
preg_match('/^[\{\[]([^\[\]\{\}]*)[\}\]](.*)/s', $part, $matches);

if (count($matches) !== 3) {
return;
return null;
}

$condition = $matches[1];
Expand Down

0 comments on commit 0e0e862

Please sign in to comment.