leaveFromGroup static method

Future<void> leaveFromGroup({
  1. required String userJid,
  2. required String groupJid,
  3. required dynamic flyCallBack(
    1. FlyResponse response
    ),
})

User Leaves from a group.

This method allows the specified user to leave the specified group.

Params:

  • userJid : The JID of the user leaving the group.
  • groupJid : The JID of the group.

Returns:

  • flyCallBack : A callback function that is called with the response.

Usage example:

Mirrorfly.leaveFromGroup(
  userJid: userJid,
  groupJid: groupJid,
  flyCallBack: (response) {
    // Handle the response
    print("User left group: $response");
  },
);

Implementation

static Future<void> leaveFromGroup(
    {required String userJid,
    required String groupJid,
    required Function(FlyResponse response) flyCallBack}) {
  return FlyChatFlutterPlatform.instance
      .leaveFromGroup(userJid, groupJid, flyCallBack);
}