File tree Expand file tree Collapse file tree 1 file changed +8
-4
lines changed
Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -28,9 +28,8 @@ protected static function bootCascadeSoftDeletes()
2828 foreach ($ model ->cascadeDeletes as $ relationship ) {
2929 if (! $ model ->{$ relationship }() instanceof Relation) {
3030 throw new LogicException (sprintf (
31- 'Relationship [%s] must return an object of type %s ' ,
32- $ relationship ,
33- Relation::class
31+ 'Relationship [%s] must return an object of type Illuminate\Database\Eloquent\SoftDeletes ' ,
32+ $ relationship
3433 ));
3534 }
3635
@@ -40,9 +39,14 @@ protected static function bootCascadeSoftDeletes()
4039 }
4140
4241
42+ /**
43+ * Determine if the current model implements soft deletes.
44+ *
45+ * @return bool
46+ */
4347 protected function implementsSoftDeletes ()
4448 {
45- return in_array (SoftDeletes::class , class_uses ($ this ));
49+ return in_array (' Illuminate\Database\Eloquent\ SoftDeletes' , class_uses ($ this ));
4650 }
4751
4852}
You can’t perform that action at this time.
0 commit comments