Skip to content

Commit 92a7094

Browse files
devoncarewcommit-bot@chromium.org
authored andcommitted
Fix three missing return warnings.
Change-Id: I69c5684a40bf46ac6a2b1ed304ea593b9d073922 Reviewed-on: https://dart-review.googlesource.com/68381 Commit-Queue: Devon Carew <devoncarew@google.com> Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
1 parent 1babc13 commit 92a7094

File tree

3 files changed

+7
-10
lines changed

3 files changed

+7
-10
lines changed

pkg/analyzer_plugin/test/integration/support/integration_tests.dart

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -951,7 +951,5 @@ abstract class _RecursiveMatcher extends Matcher {
951951
* Create a [MismatchDescriber] describing a mismatch with a simple string.
952952
*/
953953
MismatchDescriber simpleDescription(String description) =>
954-
(Description mismatchDescription) {
955-
mismatchDescription.add(description);
956-
};
954+
(Description mismatchDescription) => mismatchDescription.add(description);
957955
}

tools/testing/dart/browser_controller.dart

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1362,13 +1362,12 @@ class BrowserTestingServer {
13621362
} else {
13631363
textResponse = new Future<String>.value("");
13641364
}
1365-
request.response.done.catchError((error) {
1365+
request.response.done.catchError((error) async {
13661366
if (!underTermination) {
1367-
return textResponse.then((String text) {
1368-
print("URI ${request.uri}");
1369-
print("textResponse $textResponse");
1370-
throw "Error returning content to browser: $error";
1371-
});
1367+
String text = await textResponse;
1368+
print("URI ${request.uri}");
1369+
print("text $text");
1370+
throw "Error returning content to browser: $error";
13721371
}
13731372
});
13741373
textResponse.then((String text) async {

tools/testing/dart/command.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -656,7 +656,7 @@ class MakeSymlinkCommand extends ScriptCommand {
656656
var link = new io.Link(_link);
657657

658658
return link.exists().then((bool exists) {
659-
if (exists) return link.delete();
659+
if (exists) link.deleteSync();
660660
}).then((_) => link.create(_target));
661661
}).then((_) {
662662
return new ScriptCommandOutput(this, Expectation.pass, "", watch.elapsed);

0 commit comments

Comments
 (0)