Fix role and goal saving before using (#8177)

This commit is contained in:
Shrikant Sharat Kandula 2021-10-04 23:09:56 +05:30 committed by GitHub
parent 98c395cec7
commit 89cc2555ab
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -199,7 +199,8 @@ public class UserSignup {
userData.setUseCase(userFromRequest.getUseCase());
return Mono.when(
configService.getInstanceId()
userDataService.updateForUser(user, userData)
.then(configService.getInstanceId())
.doOnSuccess(instanceId -> analyticsService.sendEvent(
AnalyticsEvents.INSTALLATION_SETUP_COMPLETE.getEventName(),
instanceId,
@ -214,7 +215,6 @@ public class UserSignup {
"APPSMITH_DISABLE_TELEMETRY",
String.valueOf(!userFromRequest.isAllowCollectingAnonymousData())
)),
userDataService.updateForUser(user, userData),
analyticsService.sendObjectEvent(AnalyticsEvents.CREATE_SUPERUSER, user, null)
).thenReturn(user);
});