remove method
Remove key
Implementation
V? remove(Object? key) {
final newMap = Map<K, V>.from(value);
final hadKey = newMap.containsKey(key);
final removed = newMap.remove(key);
if (hadKey) value = newMap;
return removed;
}
Remove key
V? remove(Object? key) {
final newMap = Map<K, V>.from(value);
final hadKey = newMap.containsKey(key);
final removed = newMap.remove(key);
if (hadKey) value = newMap;
return removed;
}