Merge branch 'password-endpoints' of github.com:Discreetly/server into password-endpoints

This commit is contained in:
Tanner Shaw
2023-11-11 13:57:55 -06:00
2 changed files with 7 additions and 7 deletions

6
package-lock.json generated
View File

@@ -2949,9 +2949,9 @@
}
},
"node_modules/axios": {
"version": "1.5.0",
"resolved": "https://registry.npmjs.org/axios/-/axios-1.5.0.tgz",
"integrity": "sha512-D4DdjDo5CY50Qms0qGQTTw6Q44jl7zRwY7bthds06pUGfChBCTcQs+N743eFWGEd6pRTMd6A+I87aWyFV5wiZQ==",
"version": "1.6.1",
"resolved": "https://registry.npmjs.org/axios/-/axios-1.6.1.tgz",
"integrity": "sha512-vfBmhDpKafglh0EldBEbVuoe7DyAavGSLWhuSm5ZSEKQnHhBf0xAAwybbNH1IkrJNGnS/VG4I5yxig1pCEXE4g==",
"dependencies": {
"follow-redirects": "^1.15.0",
"form-data": "^4.0.0",

View File

@@ -23,14 +23,14 @@ router.post(
'/join',
limiter,
asyncHandler(async (req: Request, res: Response) => {
const { proof, idc } = req.body as { proof: SNARKProof, idc: string };
const { proof, idc } = req.body as { proof: SNARKProof; idc: string };
const isValid = await verifyTheWordProof(proof);
if (isValid) {
const room = await prisma.rooms.findUnique({
const room = (await prisma.rooms.findUnique({
where: {
roomId: '007' + process.env.THEWORD_ITERATION
roomId: '700' + process.env.THEWORD_ITERATION
}
}) as RoomI;
})) as RoomI;
const addedRoom = await addIdentityToIdentityListRooms([room], idc);
if (addedRoom.length === 0) {
res.status(500).json({