mirror of
https://github.com/hcengineering/platform.git
synced 2024-11-22 21:50:34 +03:00
Fix for null lastName during signup with google (#5328)
Signed-off-by: Praveen Erramilli <epraveenns@gmail.com>
This commit is contained in:
parent
40c292aa58
commit
9e3c9a928e
@ -1844,6 +1844,9 @@ export async function joinWithProvider (
|
||||
const email = cleanEmail(_email)
|
||||
const invite = await getInvite(db, inviteId)
|
||||
const workspace = await checkInvite(invite, email)
|
||||
if (last == null) {
|
||||
last = ''
|
||||
}
|
||||
let account = await getAccount(db, email)
|
||||
if (account == null && extra !== undefined) {
|
||||
account = await getAccountByQuery(db, extra)
|
||||
@ -1893,6 +1896,9 @@ export async function loginWithProvider (
|
||||
extra?: Record<string, string>
|
||||
): Promise<LoginInfo> {
|
||||
const email = cleanEmail(_email)
|
||||
if (last == null) {
|
||||
last = ''
|
||||
}
|
||||
let account = await getAccount(db, email)
|
||||
if (account == null && extra !== undefined) {
|
||||
account = await getAccountByQuery(db, extra)
|
||||
@ -1909,7 +1915,6 @@ export async function loginWithProvider (
|
||||
}
|
||||
return result
|
||||
}
|
||||
|
||||
const newAccount = await createAcc(ctx, db, productId, email, null, first, last, true, extra)
|
||||
|
||||
const result = {
|
||||
|
Loading…
Reference in New Issue
Block a user