diff --git a/lib/screen/detail/artwork_detail_page.dart b/lib/screen/detail/artwork_detail_page.dart index a7e9aa338..e252e2f2f 100644 --- a/lib/screen/detail/artwork_detail_page.dart +++ b/lib/screen/detail/artwork_detail_page.dart @@ -487,22 +487,20 @@ class _ArtworkDetailPageState extends State ), iconOnProcessing: ValueListenableBuilder( valueListenable: downloadProgress, - builder: (context, double value, child) { - return SizedBox( - height: 20, - width: 20, - child: CircularProgressIndicator( - value: value <= 0 ? null : value, - valueColor: value <= 0 - ? null - : AlwaysStoppedAnimation(Colors.blue), - backgroundColor: - value <= 0 ? null : AppColor.disabledColor, - color: AppColor.disabledColor, - strokeWidth: 2, - ), - ); - }), + builder: (context, double value, child) => SizedBox( + height: 20, + width: 20, + child: CircularProgressIndicator( + value: value <= 0 ? null : value, + valueColor: value <= 0 + ? null + : const AlwaysStoppedAnimation(Colors.blue), + backgroundColor: + value <= 0 ? null : AppColor.disabledColor, + color: AppColor.disabledColor, + strokeWidth: 2, + ), + )), onTap: () async { try { final file = await _feralfileService.downloadFeralfileArtwork( diff --git a/lib/util/download_helper.dart b/lib/util/download_helper.dart index 27cf05750..768d8e3cd 100644 --- a/lib/util/download_helper.dart +++ b/lib/util/download_helper.dart @@ -80,7 +80,7 @@ class DownloadHelper { log.info('Downloaded part $i/$numParts'); }); - final batchSize = 10; + const batchSize = 10; final batches = >>[]; List> batch = >[]; for (final future in downloadFeatures) {