mirror of
https://github.com/tiennm99/coolify.git
synced 2026-08-21 06:26:22 +00:00
chore: inspect commit message guidance
This commit is contained in:
@@ -104,6 +104,12 @@ class User extends Authenticatable implements SendsEmail
|
||||
$new_team->forceFill($team);
|
||||
$new_team->save();
|
||||
|
||||
if (! $user->teams()->whereKey($new_team->id)->exists()) {
|
||||
$user->teams()->attach($new_team, ['role' => 'owner']);
|
||||
} else {
|
||||
$user->teams()->updateExistingPivot($new_team->id, ['role' => 'owner']);
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user