It seems like $this->argument('name') targeting Illuminate\Console\Command::argument() can also be of type array or null; however, str_singular() does only seem to accept string, maybe add an additional type check?
This check looks at variables that are passed out again to other methods.
If the outgoing method call has stricter type requirements than the method itself, an issue is raised.
Adding a
@return
annotation to a constructor is not recommended, since a constructor does not have a meaningful return value.Please refer to the PHP core documentation on constructors.