onceDiagnostic method
void
onceDiagnostic({
- required DiagnosticHandler handler,
inherited
Implementation
void onceDiagnostic({required handler}) {
// ignore: cancel_subscriptions
var subscription = onDiagnostic(handler: handler);
subscription.onData((data) {
if (data.containsKey(HostEventType.diagnostic))
offDiagnostic(handler: handler);
});
}