How to detect peer is initialized.

Options
I want to send event after peer is initialized. How do I know peer is initialized. Now i got error like ( Peer is not initialized yet ).

Comments

  • chvetsov
    Options
    hi, @soethihanaing

    in peers constructor you have to enqueue action to peers fiber (RequestFiber). this action will be executed right after peer initialization

    best,
    ilya
  • thanks. I got it!

    this.RequestFiber(() => {
    //do stuff
    });
  • chvetsov
    Options
    yes, exactly. that is how we do this

    best,
    ilya