diff options
author | Raphael Kabo <raphaelkabo@hey.com> | 2024-02-05 19:11:10 +0000 |
---|---|---|
committer | Raphael Kabo <raphaelkabo@hey.com> | 2024-02-05 21:47:03 +0000 |
commit | 2402f88e0e907877a295350c57d2dd88edff6cd0 (patch) | |
tree | 4f8db3c6ae47a9bc15653382f269f93e5064e3fd /src/lib | |
parent | be317850f203c428f77394f824908ecff500cf78 (diff) |
Handle visibility in attendee model
Diffstat (limited to 'src/lib')
-rw-r--r-- | src/lib/activitypub.ts | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lib/activitypub.ts b/src/lib/activitypub.ts index 31c75ce..a06991d 100644 --- a/src/lib/activitypub.ts +++ b/src/lib/activitypub.ts @@ -1,5 +1,5 @@ import { Request, Response } from "express"; -import Event from "../models/Event.js"; +import Event, { IAttendee } from "../models/Event.js"; import { sendDirectMessage } from "../activitypub.js"; import { successfulRSVPResponse } from "./activitypub/templates.js"; @@ -142,7 +142,7 @@ export const handlePollResponse = async (req: Request, res: Response) => { if (!event.attendees?.some((el) => el.id === attributedTo)) { const attendeeName = apActor.preferredUsername || apActor.name || attributedTo; - const newAttendee = { + const newAttendee: Partial<IAttendee> = { name: attendeeName, status: "attending", id: attributedTo, |