Skip to content

Commit

Permalink
feat: start populating metadata under labs prefix
Browse files Browse the repository at this point in the history
  • Loading branch information
simonrose121 committed Aug 27, 2024
1 parent 5dcf4df commit efffd02
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
1 change: 1 addition & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@
"oaknational",
"oaknationalacademy",
"oclif",
"Onboarded",
"openai",
"openapi",
"paragraphise",
Expand Down
5 changes: 5 additions & 0 deletions packages/api/src/router/auth.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,12 @@ export const authRouter = router({

await clerkClient.users.updateUserMetadata(userId, {
publicMetadata: {
// legacy field for demo users. To remove after transition to labs namespace
isDemoUser,
labs: {
isDemoUser,
isOnboarded: !!input.termsOfUse,
},
},
privateMetadata: {
acceptedPrivacyPolicy: input.privacyPolicy,
Expand Down

0 comments on commit efffd02

Please sign in to comment.