Parameters
- from: ActorRef
- message:
| { CommentActorMessage: "Create" } & {
value: Omit<
{
answered: boolean;
archived?: Timestamp;
authorId: string & BRAND<"UID">;
authorName: string;
created: Timestamp;
relatedQuestion?: string & BRAND<"UID">;
relatedQuiz: string & BRAND<"UID">;
text: string;
uid: string & BRAND<"UID">;
updated: Timestamp;
upvoters: (string & BRAND<"UID">)[];
},
"uid",
>;
}
| { CommentActorMessage: "Update" } & {
value: Partial<
{
answered: boolean;
archived?: Timestamp;
authorId: string & BRAND<"UID">;
authorName: string;
created: Timestamp;
relatedQuestion?: string & BRAND<"UID">;
relatedQuiz: string & BRAND<"UID">;
text: string;
uid: string & BRAND<"UID">;
updated: Timestamp;
upvoters: (string & BRAND<"UID">)[];
},
> & { uid: string & BRAND<"UID"> };
}
| { CommentActorMessage: "Upvote" } & {
value: {
commentId: string & BRAND<"UID">;
userId: string & BRAND<"UID">;
};
}
| { CommentActorMessage: "Delete" } & { value: string & BRAND<"UID"> }
| { CommentActorMessage: "GetAll" } & { value: {} }
| { CommentActorMessage: "SubscribeToCollection" } & { value: {} }
| { CommentActorMessage: "UnsubscribeFromCollection" } & { value: {} }
Returns Promise<ResultType>
promised return value. If the caller used ask, this value will be returned to the calling actor
Actor representing the comments of a single quiz. This will be started as a child of the corresponding quiz actor