cleanupSegments function

Iterable<String> cleanupSegments(
  1. Iterable<String> segments
)

Implementation

Iterable<String> cleanupSegments(Iterable<String> segments) {
  final ret = <String>[];
  for (String seg in segments) {
    if (seg.isEmpty) continue;
    ret.add(seg);
  }
  return ret;
}