sendGift method

Future<TUIActionCallback> sendGift(
  1. TUIGiftInfo giftInfo,
  2. int count
)

Implementation

Future<TUIActionCallback> sendGift(TUIGiftInfo giftInfo, int count) async {
  final result = await giftManager.sendGift(giftInfo, count);
  if (result.code != TUIError.success) {
    TUIGiftStore().onError?.call(result.code.rawValue, result.message ?? '');
    return result;
  }
  onSendGiftCallback?.call(giftInfo, count);
  return result;
}