remove method

  1. @override
V? remove(
  1. Object? key
)
override

Removes the entry for the given key and returns its value.

Returns the value associated with key, or null if key is not present. Notifies subscribers if an entry was removed.

Implementation

@override
V? remove(Object? key) {
  if (peek.containsKey(key)) {
    final v = peek.remove(key);
    notify();
    return v;
  } else {
    return peek.remove(key);
  }
}