fix: review and refactoring.

This commit is contained in:
charlesgauthereau
2026-02-11 12:18:25 +01:00
parent feb06a85ae
commit 824ef4528e
4 changed files with 8 additions and 8 deletions
-4
View File
@@ -1,11 +1,8 @@
import {EventEmitter} from 'events';
import {auth} from "@/lib/auth/auth";
import {headers} from "next/headers";
import {NextResponse} from "next/server";
import {eventEmitter} from "@/features/shared/event";
// export const eventEmitter = new EventEmitter();
export async function GET(request: Request) {
const session = await auth.api.getSession({
@@ -28,7 +25,6 @@ export async function GET(request: Request) {
eventEmitter.on('modification', handleModification);
// Handle client disconnect
request.signal.addEventListener('abort', () => {
console.log('Client disconnected');
controller.close();