diff --git a/packages/backend/src/routes/auth.ts b/packages/backend/src/routes/auth.ts index 62071660..c5b5a471 100644 --- a/packages/backend/src/routes/auth.ts +++ b/packages/backend/src/routes/auth.ts @@ -66,10 +66,10 @@ router.post('/validate', async (req, res) => { } const newUser = await service.createUser({ ethAddress: data.address, - email: '', - name: '', - subOrgId: '', - turnkeyWalletId: '', + email: data.address, + name: data.address, + subOrgId: data.address, + turnkeyWalletId: data.address, // TODO: fix fields }); req.session.userId = newUser.id; } else if (action === 'login') { diff --git a/packages/backend/src/service.ts b/packages/backend/src/service.ts index 692ee577..debdc9a3 100644 --- a/packages/backend/src/service.ts +++ b/packages/backend/src/service.ts @@ -414,6 +414,9 @@ export class Service { if (!user) { user = await this.db.addUser({ email: data.email, + ethAddress: data.email, + subOrgId: data.email, + turnkeyWalletId: data.email, }); }