Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(118)

Unified Diff: lib/src/utils.dart

Issue 1664433002: Support shelf 0.7.0. (Closed) Base URL: git@github.com:dart-lang/test@master
Patch Set: Code review changes Created 4 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « lib/src/util/stream_channel.dart ('k') | pubspec.yaml » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/src/utils.dart
diff --git a/lib/src/utils.dart b/lib/src/utils.dart
index 24737b4d270ced2b89f798f71fb8f7be942dc66b..4b554ee53ecb93b01f83a3f231b7d42b29b43168 100644
--- a/lib/src/utils.dart
+++ b/lib/src/utils.dart
@@ -208,16 +208,6 @@ Map mergeMaps(Map map1, Map map2) {
return result;
}
-/// Returns a sink that maps events sent to [original] using [fn].
-StreamSink mapSink(StreamSink original, fn(event)) {
- var controller = new StreamController(sync: true);
- controller.stream.listen(
- (event) => original.add(fn(event)),
- onError: (error, stackTrace) => original.addError(error, stackTrace),
- onDone: () => original.close());
- return controller.sink;
-}
-
/// Like [runZoned], but [zoneValues] are set for the callbacks in
/// [zoneSpecification] and [onError].
runZonedWithValues(body(), {Map zoneValues,
« no previous file with comments | « lib/src/util/stream_channel.dart ('k') | pubspec.yaml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698