mirror of
https://github.com/barryvdh/laravel-ide-helper.git
synced 2026-08-18 18:13:11 +00:00
Include return value when generating scope methods
It's handy to specify return values in phpDoc comments. This patch sets the return value to the containing class.
This commit is contained in:
@@ -238,7 +238,7 @@ class ModelsCommand extends Command {
|
||||
$args = $this->getParameters($reflection);
|
||||
//Remove the first ($query) argument
|
||||
array_shift($args);
|
||||
$this->setMethod($name, 'static', $args);
|
||||
$this->setMethod($name, "static " . $reflection->class, $args);
|
||||
}
|
||||
}elseif(!method_exists('Eloquent', $method) && !\Str::startsWith($method, 'get')){
|
||||
|
||||
|
||||
Reference in New Issue
Block a user