Support the ongoing development of Laravel.io →
posted 9 years ago
IOC
Last updated 1 year ago.
0

The resolution I found was to create an ObserverServiceProvider and place it after DatabaseServiceProvider in the config/app.php file.

Because the event dispatcher is attached to the base Model class in DatabaseServiceProvider. Once event is dispatched in DatabaseServiceProvider we can use Observer.

0

Thanks, saved me a good amount of more debugging.

0

You looked at the event solution that comes as part of L5?

https://laracasts.com/lessons/laravel-5-events

0

Sign in to participate in this thread!

Eventy

Your banner here too?

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.