mirror of
https://github.com/solidtime-io/solidtime.git
synced 2026-08-08 08:12:17 +01:00
Fixed current organization after normal registration
This commit is contained in:
committed by
Constantin Graf
parent
24775d2c47
commit
0c825a691e
@@ -62,6 +62,7 @@ class UserService
|
||||
$intervalFormat,
|
||||
$timeFormat,
|
||||
);
|
||||
$this->switchCurrentOrganization($user, $organization);
|
||||
}
|
||||
|
||||
return $user;
|
||||
|
||||
@@ -61,6 +61,7 @@ class RegistrationTest extends TestCaseWithDatabase
|
||||
$member = Member::query()->whereBelongsTo($user, 'user')->whereBelongsTo($organization, 'organization')->firstOrFail();
|
||||
$this->assertSame(Role::Owner->value, $member->role);
|
||||
Event::assertNotDispatched(NewsletterRegistered::class);
|
||||
$this->assertSame($organization->getKey(), $user->current_team_id);
|
||||
}
|
||||
|
||||
public function test_user_registration_fails_if_registration_is_deactivated(): void
|
||||
|
||||
Reference in New Issue
Block a user