deleteAttempts abstract method

Future<int> deleteAttempts(
  1. Session session, {
  2. String? key,
  3. Duration? olderThan,
  4. Transaction? transaction,
})

Deletes attempts within this limiter's domain and source.

If key is omitted, matches every key in this scope. If olderThan is provided, only attempts strictly older than that duration are removed, measured from the current time. Omitting olderThan removes all matching attempts, regardless of the configured window. Returns the number of deleted attempts.

Implementation

Future<int> deleteAttempts(
  final Session session, {
  final String? key,
  final Duration? olderThan,
  final Transaction? transaction,
});