seyfert
    Preparing search index...

    Class Poll

    Hierarchy

    • ObjectToLower<APIPoll>
    • Base
      • Poll
    Index

    Constructors

    • Parameters

      • client: UsingClient
      • data: APIPoll
      • channelId: string
      • messageId: string

      Returns Poll

    Properties

    allowMultiselect: boolean
    answers: {
        answerId: number;
        pollMedia: {
            emoji?: { animated?: boolean; id: null | string; name: null | string };
            text?: string;
        };
    }[]
    channelId: string
    client: UsingClient
    expiry: string
    layoutType: PollLayoutType
    messageId: string
    question: {
        emoji?: { animated?: boolean; id: null | string; name: null | string };
        text?: string;
    }
    results?: {
        answerCounts: { count: number; id: number; meVoted: boolean }[];
        isFinalized: boolean;
    }

    Accessors

    Methods

    • Parameters

      • id: ValidAnswerId

        The ID of the answer whose voters need to be fetched.

      • checkAnswer: boolean = false

        A flag that determines if the answer ID should be validated before fetching voters. Default is false. If true, the method checks if the answer ID exists in the list of answers and throws an error if not.

      Returns Promise<User[]>