add is_external to upsert profile
This commit is contained in:
@@ -174,6 +174,7 @@ export async function upsertProfile({
|
|||||||
avatar,
|
avatar,
|
||||||
properties,
|
properties,
|
||||||
projectId,
|
projectId,
|
||||||
|
isExternal,
|
||||||
}: IServiceUpsertProfile) {
|
}: IServiceUpsertProfile) {
|
||||||
const [profile] = await chQuery<IClickhouseProfile>(
|
const [profile] = await chQuery<IClickhouseProfile>(
|
||||||
`SELECT * FROM profiles WHERE id = ${escape(id)} AND project_id = ${escape(projectId)} ORDER BY created_at DESC LIMIT 1`
|
`SELECT * FROM profiles WHERE id = ${escape(id)} AND project_id = ${escape(projectId)} ORDER BY created_at DESC LIMIT 1`
|
||||||
@@ -198,6 +199,7 @@ export async function upsertProfile({
|
|||||||
}),
|
}),
|
||||||
project_id: projectId ?? profile?.project_id ?? '',
|
project_id: projectId ?? profile?.project_id ?? '',
|
||||||
created_at: new Date(),
|
created_at: new Date(),
|
||||||
|
is_external: isExternal,
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user