mikebronner/laravel-model-caching

Pivot model not invalidating cache.

Opened this issue · 2 comments

@mikebronner I just seen a potential issue when using pivot models (https://laravel.com/docs/12.x/eloquent-relationships#defining-custom-intermediate-table-models).
Cache is not invalidated once an attachement or detachment is processed trough such a pivot model, in fact, the action is not detected at all in pivotSynced, pivotAttached, ... events.
Is this something that is not yet covered by the package ?

Originally posted by @Okipa in #479

@Okipa I'll have to dig in and verify. If anyone else knows, please chime in.

Related discussions: