Unverified Commit 81b98450 authored by Jonah Williams's avatar Jonah Williams Committed by GitHub

[flutter_tools] migrate async_guard.dart to null safety (#76748)

parent 9d53c11e
......@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// @dart = 2.8
import 'dart:async';
/// Runs [fn] with special handling of asynchronous errors.
......@@ -82,7 +80,7 @@ import 'dart:async';
/// [ArgumentError] will be thrown synchronously.
Future<T> asyncGuard<T>(
Future<T> Function() fn, {
Function onError,
Function? onError,
}) {
if (onError != null &&
onError is! _UnaryOnError<T> &&
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment