format codebase with prettier

This commit is contained in:
2026-01-04 16:17:36 +01:00
parent 77f15b6dd1
commit e3f7a778c7
63 changed files with 786 additions and 542 deletions

View File

@@ -1,7 +1,12 @@
import { Response } from 'express';
import { SendMessageDTO, CreateEventDTO, UpdateEventDTO, EventAction } from '@caldav/shared';
import { ChatService } from '../services';
import { AuthenticatedRequest } from '../middleware';
import { Response } from "express";
import {
SendMessageDTO,
CreateEventDTO,
UpdateEventDTO,
EventAction,
} from "@caldav/shared";
import { ChatService } from "../services";
import { AuthenticatedRequest } from "../middleware";
export class ChatController {
constructor(private chatService: ChatService) {}
@@ -13,7 +18,7 @@ export class ChatController {
const response = await this.chatService.processMessage(userId, data);
res.json(response);
} catch (error) {
res.status(500).json({ error: 'Failed to process message' });
res.status(500).json({ error: "Failed to process message" });
}
}
@@ -34,11 +39,11 @@ export class ChatController {
action,
event,
eventId,
updates
updates,
);
res.json(response);
} catch (error) {
res.status(500).json({ error: 'Failed to confirm event' });
res.status(500).json({ error: "Failed to confirm event" });
}
}
@@ -46,18 +51,28 @@ export class ChatController {
try {
const userId = req.user!.userId;
const { conversationId, messageId } = req.params;
const response = await this.chatService.rejectEvent(userId, conversationId, messageId);
const response = await this.chatService.rejectEvent(
userId,
conversationId,
messageId,
);
res.json(response);
} catch (error) {
res.status(500).json({ error: 'Failed to reject event' });
res.status(500).json({ error: "Failed to reject event" });
}
}
async getConversations(req: AuthenticatedRequest, res: Response): Promise<void> {
throw new Error('Not implemented');
async getConversations(
req: AuthenticatedRequest,
res: Response,
): Promise<void> {
throw new Error("Not implemented");
}
async getConversation(req: AuthenticatedRequest, res: Response): Promise<void> {
throw new Error('Not implemented');
async getConversation(
req: AuthenticatedRequest,
res: Response,
): Promise<void> {
throw new Error("Not implemented");
}
}