Skip to content

Commit

Permalink
Fixed PHP 8.4 deprecation warning (#1622)
Browse files Browse the repository at this point in the history
* Fixed PHP 8.4 deprecation warning

* Fix PHP 8.4 deprecation warning
  • Loading branch information
eusonlito authored Dec 9, 2024
1 parent 788e72e commit 5da09fa
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
3 changes: 2 additions & 1 deletion src/Console/ModelsCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -1301,10 +1301,11 @@ protected function getCommentFromDocBlock(\ReflectionMethod $reflection)
* Get method return type based on it DocBlock comment
*
* @param \ReflectionMethod $reflection
* @param ?\Reflector $reflectorForContext
*
* @return null|string
*/
protected function getReturnTypeFromDocBlock(\ReflectionMethod $reflection, \Reflector $reflectorForContext = null)
protected function getReturnTypeFromDocBlock(\ReflectionMethod $reflection, ?\Reflector $reflectorForContext = null)
{
$phpDocContext = (new ContextFactory())->createFromReflector($reflectorForContext ?? $reflection);
$context = new Context(
Expand Down
4 changes: 2 additions & 2 deletions src/Generator.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,15 +42,15 @@ class Generator
/**
* @param \Illuminate\Config\Repository $config
* @param \Illuminate\View\Factory $view
* @param OutputInterface $output
* @param ?OutputInterface $output
* @param string $helpers
*/
public function __construct(
/*ConfigRepository */
$config,
/* Illuminate\View\Factory */
$view,
OutputInterface $output = null,
?OutputInterface $output = null,
$helpers = ''
) {
$this->config = $config;
Expand Down

0 comments on commit 5da09fa

Please # to comment.