decrement method
Decrement the value of an item in the cache.
- Parameters:
key: The key of the item to decrement.amount: The amount to decrement by (default is 1).
- Returns: The new value of the item.
Implementation
@override
Future<int> decrement(String key, [int amount = 1]) async {
return increment(key, -amount);
}