Skip to content

Commit 5524d6c

Browse files
committed
Fixed lazychaser#91: removed param type from event callbacks since failing in php 7
1 parent c1fa393 commit 5524d6c

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/NodeTrait.php

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -45,37 +45,37 @@ trait NodeTrait
4545
*/
4646
public static function bootNodeTrait()
4747
{
48-
static::saving(function (self $model) {
48+
static::saving(function ($model) {
4949
$model->getConnection()->beginTransaction();
5050

5151
return $model->callPendingAction();
5252
});
5353

54-
static::saved(function (self $model) {
54+
static::saved(function ($model) {
5555
$model->getConnection()->commit();
5656
});
5757

58-
static::deleting(function (self $model) {
58+
static::deleting(function ($model) {
5959
$model->getConnection()->beginTransaction();
6060

6161
// We will need fresh data to delete node safely
6262
$model->refreshNode();
6363
});
6464

65-
static::deleted(function (self $model) {
65+
static::deleted(function ($model) {
6666
$model->deleteDescendants();
6767

6868
$model->getConnection()->commit();
6969
});
7070

7171
if (static::usesSoftDelete()) {
72-
static::restoring(function (self $model) {
72+
static::restoring(function ($model) {
7373
$model->getConnection()->beginTransaction();
7474

7575
static::$deletedAt = $model->{$model->getDeletedAtColumn()};
7676
});
7777

78-
static::restored(function (self $model) {
78+
static::restored(function ($model) {
7979
$model->restoreDescendants(static::$deletedAt);
8080

8181
$model->getConnection()->commit();

0 commit comments

Comments
 (0)