pauseSubscriptionForCurrentUser method

  1. @override
Future<String?> pauseSubscriptionForCurrentUser({
  1. required String productId,
  2. int? pauseDurationDays,
})
override

1.3.0 no-userId overload — uses the currently identified user. Takes pauseDurationDays per Kit 1.3.0 (replaces the old pauseOptionId).

Implementation

@override
Future<String?> pauseSubscriptionForCurrentUser({required String productId, int? pauseDurationDays}) async {
  final result = await methodChannel.invokeMethod<String>('pauseSubscription', {
    'productId': productId,
    if (pauseDurationDays != null) 'pauseDurationDays': pauseDurationDays,
  });
  return result;
}