Unable to send first message after ticket creation

“sendbird-desk”: “^1.0.22”

I followed the documentation given here: Create your first ticket | Desk JavaScript SDK | Sendbird Docs

I have a text input element to get the first message to be sent on ticket creation and the value is stored in ticketTextInput as string.

And this is my function that is called when a button is clicked, by passing this function to its onClick method:

  const createSBTicket = () => {
    const message: UserMessageCreateParams = {
      message: ticketTextInput

    Ticket.getAllTickets(0, (tickets, error) => {
      if (error) {
      const ticketsLength = tickets.length;
      console.log("ticketsLength", ticketsLength);
      // offset += tickets.length; for the next tickets.
      // Implement your code to display the ticket list.
      Ticket.create("Conversation #" + ticketsLength.toString(), "", (ticket, error) => {
        if (error) {
          // Handle error.
        // The ticket.channel property indicates the group channel object within the ticket.
        // @ts-ignore



When I click on the button after entering a text in the input box, I get this error on Chrome.

See the follow-up message on this thread for the error I get on Safari for the same action.

What could be the issue here? Thanks in advance.

I get this error log on Safari for the same action