diff --git a/lib/widgets/matrix.dart b/lib/widgets/matrix.dart index 96eaeb00ad..6ae540f006 100644 --- a/lib/widgets/matrix.dart +++ b/lib/widgets/matrix.dart @@ -117,8 +117,8 @@ class MatrixState extends State with WidgetsBindingObserver { Map> get accountBundles { final resBundles = >{}; - for (var i = 0; i < widget.clients.length; i++) { - final bundles = widget.clients[i].accountBundles; + for (Client client in widget.clients) { + final bundles = client.accountBundles; for (final bundle in bundles) { if (bundle.name == null) { continue; @@ -126,7 +126,7 @@ class MatrixState extends State with WidgetsBindingObserver { resBundles[bundle.name] ??= []; resBundles[bundle.name]!.add( _AccountBundleWithClient( - client: widget.clients[i], + client: client, bundle: bundle, ), );