Added settings for user data deletion
This commit is contained in:
parent
59e15cfde8
commit
f49490042a
35 changed files with 2758 additions and 499 deletions
6
backend/dist/socket/index.js
vendored
6
backend/dist/socket/index.js
vendored
|
|
@ -1,7 +1,7 @@
|
|||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.default = setupSocket;
|
||||
const index_js_1 = require("../index.js");
|
||||
const index_1 = require("../index");
|
||||
function setupSocket(io) {
|
||||
io.on('connection', (socket) => {
|
||||
console.log('Client connected:', socket.id);
|
||||
|
|
@ -13,7 +13,7 @@ function setupSocket(io) {
|
|||
socket.leave(`game:${gameId}`);
|
||||
});
|
||||
socket.on('team-location', async (data) => {
|
||||
await index_js_1.prisma.team.update({
|
||||
await index_1.prisma.team.update({
|
||||
where: { id: data.teamId },
|
||||
data: { lat: data.lat, lng: data.lng }
|
||||
});
|
||||
|
|
@ -24,7 +24,7 @@ function setupSocket(io) {
|
|||
});
|
||||
});
|
||||
socket.on('chat-message', async (data) => {
|
||||
const chatMessage = await index_js_1.prisma.chatMessage.create({
|
||||
const chatMessage = await index_1.prisma.chatMessage.create({
|
||||
data: {
|
||||
gameId: data.gameId,
|
||||
teamId: data.teamId,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue