You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
And this causes an exception becase $user object is null in console environment while ide-helper tries to access and read it.
I have to add this custom logic in start of method:
if (app()->runningInConsole()) {
returnnewAttribute( get: fn() => false );
}
But I think this custom logic is a very bad way and it needs to fix on ide-helper.
I think may be an option is needed in ide-helper config to tell it to do not process Attribute body and just generate its name for some Attributes to prevent calculation and developer logic exceptions.
Thank you much
The text was updated successfully, but these errors were encountered:
Versions:
Description:
There is exception when an virtual attribute created and it has some calculations based on queries or authentcated user.
Example:
And this causes an exception becase
$user
object is null in console environment while ide-helper tries to access and read it.I have to add this custom logic in start of method:
But I think this custom logic is a very bad way and it needs to fix on ide-helper.
I think may be an option is needed in ide-helper config to tell it to do not process Attribute body and just generate its name for some Attributes to prevent calculation and developer logic exceptions.
Thank you much
The text was updated successfully, but these errors were encountered: