this is my code
public function GetUsersWhoNeedPayments()
{
$All_DB_Email_Info = DB::table('users')->pluck('email');
foreach($All_DB_Email_Info as $ADEI){
$DisplayUserToReceivePaymentFrom = Auth::user()->where([
['paired_with', '=', $ADEI]
])->get();
var_dump($DisplayUserToReceivePaymentFrom->name);
}
}
So I created the variable $All_DB_Email_Info which selects the email column. my goal is to get the email saved in my DB...every user is paired to make payment to other users...so i am paired to make payment to johndoe@example.com,,i want the check the db for johndoe@example.com and then check for he's ->name, phonenumber->, ->age, etc..but when i reload my page the page says 'Exception in Colection.php line 1498: Property [name] does not exist on this collection instance.' Please help me out
via OG Paul Caleb