Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[8.x] SoftDelete merge deleting event attributes #33619

Closed
wants to merge 4 commits into from
Closed

[8.x] SoftDelete merge deleting event attributes #33619

wants to merge 4 commits into from

Conversation

ghost
Copy link

@ghost ghost commented Jul 22, 2020

Soft delete: "deleting" event does not automatically update the model before it is soft deleted.

Currently, attribute change not working on Soft Deleting event;

/**
 * Handle the user "deleting" event.
 *
 * @param  \App\Models\User $user
 * @return void
 */
public function deleting(User $user)
{
    $user->eraser_ip = Request::ip();
}

And this PR solves this issue.

Related issue: #4990

Musa added 4 commits July 22, 2020 17:07
Soft delete: "deleting" event does not automatically update the model before it is soft deleted.

Solves: #4990
@taylorotwell
Copy link
Member

No plans to introduce this breaking change.

@ghost
Copy link
Author

ghost commented Jul 22, 2020

@taylorotwell This isn't a BC for me, actually can send to 7.x branch too.

@ghost ghost deleted the patch-6 branch August 17, 2020 17:45
@lucas-istak
Copy link

There is another PR that corrects this issue?

I'm using Laravel 11.x and the "deleting" event still doesn't automatically update the model before it is soft deleted.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants