• Filter updates by type of the chat where they happened

    Type Parameters

    Parameters

    • type: T

    Returns filters.UpdateFilter<
        Obj,
        { chat: T extends "user" ? User : Modify<Chat, { chatType: T }> } & (
            Obj extends Message
                ? T extends "user" | "group" ? { sender: User } : { sender: Chat }
                : EmptyObject
        ),
    >