updateGroupProfileImage method

dynamic updateGroupProfileImage(
  1. String path,
  2. BuildContext context
)

Implementation

updateGroupProfileImage(String path, BuildContext context) {
  if (!availableFeatures.value.isGroupChatAvailable.checkNull()) {
    Helper.showFeatureUnavailable(context);
    return;
  }
  showLoader(context);
  Mirrorfly.updateGroupProfileImage(
      jid: profile.jid.checkNull(),
      file: path,
      flyCallBack: (FlyResponse response) {
        hideLoader(context);
        if (response.isSuccess) {
          profile_.value.image = path;
          profile_.refresh();
        }
      });
}