Support the ongoing development of Laravel.io →
Requests Eloquent IOC
Last updated 2 years ago.
0
Solution

I solved it by calling the visitor relation as function:

Visitor::get()->reservation()->someMethod();

It may be because the relationships are cached on system startup and when the function is called it is reloaded.

0

Sign in to participate in this thread!

Eventy

Your banner here too?

jsertx jsertx Joined 28 Sep 2015

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.