Skip to content

Commit

Permalink
Add try/catch
Browse files Browse the repository at this point in the history
  • Loading branch information
timvanoostrom committed Dec 1, 2023
1 parent da8f4f7 commit 204372b
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/server/services/visitors.ts
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,12 @@ async function setupTables() {
ADD IF NOT EXISTS "authMethod" VARCHAR(100);
`;

await query(createTableQuery);
await query(alterTableQuery1);
try {
await query(createTableQuery);
await query(alterTableQuery1);
} catch (error) {
Sentry.captureException(error);
}
} else {
// Create the table
execDB(`
Expand Down

0 comments on commit 204372b

Please sign in to comment.