Get All Groups

To get groups from local or server, call below method

    GroupManager.shared.getGroups(fetchFromServer: true) { isSuccess, flyError, flyData in
    var data = flyData
    if isSuccess {
    // Update UI
    } else{
    // failure cases
    fetchFromServerBoolif fetchFromServer is true, groups will be feteched from server or else from local
    completionHandlerFlyCompletionHandlercallback to get success or failure response. implemented as closure expression

    func didFetchGroups(groups : [ProfileDetails], message : String) method will be called, which is defined in GroupEventsDelegate.