MediaSFU React Native
    Preparing search index...

    Function handleEndPoll

    • Handles the end of a poll by emitting an "endPoll" event through the provided socket. Displays an alert based on the success or failure of the operation.

      Parameters

      • options: HandleEndPollOptions

        The options for ending the poll.

        • pollId: string
        • socket: Socket
        • OptionalshowAlert?: ShowAlert
        • roomName: string
        • updateIsPollModalVisible: (isVisible: boolean) => void

      Returns Promise<void>

      handleEndPoll({
      pollId: "poll123",
      socket: socketInstance,
      showAlert: (message) => console.log(message),
      roomName: "roomA",
      updateIsPollModalVisible: (isVisible) => setIsPollModalVisible(isVisible),
      });