import { Handlers } from "$fresh/server.ts";
import { createStreamResponse } from "@lib/helpers.ts";

const activeResponses: ReturnType<typeof createStreamResponse>[] = [];

export const handler: Handlers = {
  GET() {
    const r = createStreamResponse();

    activeResponses.push(r);

    return r.response;
  },
};
