Skip to content

Commit

Permalink
fix typo
Browse files Browse the repository at this point in the history
  • Loading branch information
Joseph Damiba authored and Joseph Damiba committed Sep 21, 2024
1 parent b9e6707 commit bab334d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/api/clerk_webhook/route.ts
Original file line number Diff line number Diff line change
Expand Up @@ -70,13 +70,13 @@ export async function POST(req: Request) {
try {
// Insert or update user in the database
await sql`
INSERT INTO users (user_id, email, first_name, last_name, image_url, created_at, subscription_tier)
INSERT INTO users (id, email, first_name, last_name, image_url, created_at, subscription_tier)
VALUES (${id}, ${primaryEmail.email_address}, ${
first_name || null
}, ${last_name || null}, ${image_url || null}, to_timestamp(${
created_at / 1000
}), 'free')
ON CONFLICT (user_id) DO UPDATE SET
ON CONFLICT (id) DO UPDATE SET
email = EXCLUDED.email,
first_name = EXCLUDED.first_name,
last_name = EXCLUDED.last_name,
Expand Down

0 comments on commit bab334d

Please sign in to comment.