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

Booted method of parent called #124

Open
jorisnoo opened this issue Jan 18, 2024 · 0 comments
Open

Booted method of parent called #124

jorisnoo opened this issue Jan 18, 2024 · 0 comments

Comments

@jorisnoo
Copy link

jorisnoo commented Jan 18, 2024

Hi there, and first of all many thanks for all the effort put into this great and helpful package! 🙏

With the latest release 1.3.6, it appears that some behaviour has changed. I have both a parent and a child model that both implement a booted method:

protected static function booted(): void
    {
        static::creating(static function (self $model) {
            //
        });
    }

Now, when creating a new Child model, it seems like the creating method of the child model is no longer invoked, but the booted method of the parent is called instead. Is this the expected behaviour, or am I missing something?

Thank you!

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

No branches or pull requests

1 participant