Add initial sentry setup

Related to #343 but will probably need a few more changes
This commit is contained in:
Kurt Hutten
2021-06-05 20:32:56 +10:00
parent c38f94558a
commit 2e91c74baf
8 changed files with 230 additions and 4 deletions

View File

@@ -1,8 +1,9 @@
import { createUserInsecure } from 'src/services/users/users.js'
import { db } from 'src/lib/db'
import { sentryWrapper } from 'src/lib/sentry'
import { enforceAlphaNumeric, generateUniqueString } from 'src/services/helpers'
export const handler = async (req, _context) => {
const unWrappedHandler = async (req, _context) => {
const body = JSON.parse(req.body)
console.log(body)
console.log(_context)
@@ -82,3 +83,5 @@ export const handler = async (req, _context) => {
}
}
}
export const handler = sentryWrapper(unWrappedHandler)