mirror of
https://github.com/barryvdh/laravel-ide-helper.git
synced 2026-08-18 01:57:13 +00:00
Remove unnecessary and wrong definition of SoftDelete methods (#918)
These two methods are already regular methods on the trait, there's no need to add them and additionally they're not static, so their definition was changed for the worse. The other methods are magic so it's fine to keep them. Fixes https://github.com/barryvdh/laravel-ide-helper/issues/917
This commit is contained in:
@@ -843,9 +843,6 @@ class ModelsCommand extends Command
|
||||
{
|
||||
$traits = class_uses(get_class($model), true);
|
||||
if (in_array('Illuminate\\Database\\Eloquent\\SoftDeletes', $traits)) {
|
||||
$this->setMethod('forceDelete', 'bool|null', []);
|
||||
$this->setMethod('restore', 'bool|null', []);
|
||||
|
||||
$this->setMethod('withTrashed', '\Illuminate\Database\Query\Builder|\\' . get_class($model), []);
|
||||
$this->setMethod('withoutTrashed', '\Illuminate\Database\Query\Builder|\\' . get_class($model), []);
|
||||
$this->setMethod('onlyTrashed', '\Illuminate\Database\Query\Builder|\\' . get_class($model), []);
|
||||
|
||||
Reference in New Issue
Block a user