feat: Added team creation, closes #22
All checks were successful
Build and Deploy / Deploy Web (push) Successful in 1m1s
Build and Deploy / Deploy Discord Bot (push) Successful in 42s

This commit is contained in:
2023-06-06 14:29:05 +02:00
parent e68097d813
commit 9510e8a407
3 changed files with 30 additions and 0 deletions

View File

@@ -0,0 +1,12 @@
export default defineEventHandler(async (event) => {
const { name, color } = await readBody(event)
const team = new TeamModel({
name,
color
})
await team.save()
return team
})