@@ -78,13 +78,10 @@ class CachedNetworkImageProvider
7878 codec: _loadBufferAsync (key, chunkEvents, decode),
7979 chunkEvents: chunkEvents.stream,
8080 scale: key.scale,
81- informationCollector: () sync * {
82- yield DiagnosticsProperty <ImageProvider >(
83- 'Image provider: $this \n Image key: $key ' ,
84- this ,
85- style: DiagnosticsTreeStyle .errorProperty,
86- );
87- },
81+ informationCollector: () => < DiagnosticsNode > [
82+ DiagnosticsProperty <ImageProvider >('Image provider' , this ),
83+ DiagnosticsProperty <CachedNetworkImageProvider >('Image key' , key),
84+ ],
8885 );
8986
9087 if (errorListener != null ) {
@@ -132,13 +129,10 @@ class CachedNetworkImageProvider
132129 codec: _loadImageAsync (key, chunkEvents, decode),
133130 chunkEvents: chunkEvents.stream,
134131 scale: key.scale,
135- informationCollector: () sync * {
136- yield DiagnosticsProperty <ImageProvider >(
137- 'Image provider: $this \n Image key: $key ' ,
138- this ,
139- style: DiagnosticsTreeStyle .errorProperty,
140- );
141- },
132+ informationCollector: () => < DiagnosticsNode > [
133+ DiagnosticsProperty <ImageProvider >('Image provider' , this ),
134+ DiagnosticsProperty <CachedNetworkImageProvider >('Image key' , key),
135+ ],
142136 );
143137
144138 if (errorListener != null ) {
0 commit comments