anchor.diff:      // We push the banner message in a post frame callback because otherwise,
       // we'd be trying to call setState while the parent widget `BannerMessages`
       // is in the middle of `build`.
  -    WidgetsBinding.instance.addPostFrameCallback((_) {
  +    WidgetsBinding.instance!.addPostFrameCallback((_) {
         if (dismiss) {
           assert(!_dismissedMessageKeys.contains(message.key));
           _dismissedMessageKeys.add(message.key);
  
positive.code: 
  class BannerMessagesController {
    final _messages = <String, ValueNotifier<List<BannerMessage>>>{};
    final _dismissedMessageKeys = <Key>{};
  
    void addMessage(BannerMessage message) {
      // We push the banner message in a post frame callback because otherwise,
      // we'd be trying to call setState while the parent widget `BannerMessages`
      // is in the middle of `build`.
      WidgetsBinding.instance.addPostFrameCallback((_) {
        if (isMessageDismissed(message) || isMessageVisible(message)) return;
        final messages = _messagesForScreen(message.screenId);
        messages.value.add(message);
  
negative.code: // Use of this source code is governed by a BSD-style license that can be
  // found in the LICENSE file.
  
  // ignore_for_file: import_of_legacy_library_into_null_safe
  
  import 'package:collection/collection.dart' show IterableExtension;
  import 'package:flutter/foundation.dart';
  import 'package:flutter/material.dart';
  import 'package:provider/provider.dart';
  