removeNull method Null safety

void removeNull()

移除掉空的

Implementation

void removeNull() {
  if (this == null || this!.isEmpty) return;
  var keys = List.from(this!.keys);
  for (Object key in keys) {
    if (this![key] == null) this?.remove(key);
  }
  keys.clear();
}