Accessing a custom object with instanceof |
The specific error is: Class 'LN_Account' not found
The model is like this: PHP Code: namespace App\Models; LN_Account is in app\Libraries PHP Code: namespace App\Libraries; if I print_r $credentials inside the model/method I get this, so the controller knows what it is and created it. PHP Code: App\Libraries\LN_Account Object Okay so the outer if ($account instanceof LN_Account) seems to work now, it's this that doesn't: $credentials = $query->getCustomRowObject(0, 'LN_Account') Do I have to instantiate a new LN_Account() for it to use? I figured it would do it automatically. |
Messages In This Thread |
Accessing a custom object with instanceof - by baxterheinen - 01-25-2021, 11:36 PM
RE: Accessing a custom object with instanceof - by craig - 01-26-2021, 01:09 AM
RE: Accessing a custom object with instanceof - by baxterheinen - 01-26-2021, 11:35 AM
RE: Accessing a custom object with instanceof - by natanfelles - 01-26-2021, 04:32 PM
RE: Accessing a custom object with instanceof - by baxterheinen - 01-26-2021, 06:18 PM
RE: Accessing a custom object with instanceof - by iRedds - 01-26-2021, 06:34 PM
RE: Accessing a custom object with instanceof - by baxterheinen - 01-26-2021, 06:37 PM
RE: Accessing a custom object with instanceof - by iRedds - 01-26-2021, 11:19 PM
RE: Accessing a custom object with instanceof - by InsiteFX - 01-27-2021, 02:20 AM
|