If you have a belongsTo()
relationship, you can update the Eloquent relationship data in the same sentence:
// if Project -> belongsTo(User::class)$project->user->update(['email' => 'some@gmail.com']);
If you have a belongsTo()
relationship, you can update the Eloquent relationship data in the same sentence:
// if Project -> belongsTo(User::class)$project->user->update(['email' => 'some@gmail.com']);