Fix web build: use dynamic cast for Blob arguments

This commit is contained in:
Leon Bösche
2026-01-25 01:37:22 +01:00
parent edced8825d
commit edf83de94c
2 changed files with 2 additions and 2 deletions

View File

@@ -109,7 +109,7 @@ class _PublicFileViewerState extends State<PublicFileViewer> {
final mimeType =
_fileData?['capabilities']?['mimeType'] ?? 'video/mp4';
final blob = web.Blob(
[Uint8List.fromList(bytes)], // ignore: argument_type_not_assignable
[Uint8List.fromList(bytes)] as dynamic,
web.BlobPropertyBag(type: mimeType),
);
videoUrl = web.URL.createObjectURL(blob);

View File

@@ -54,7 +54,7 @@ class AudioPlayer {
final path = url.replaceFirst(apiClient.baseUrl, '');
final bytes = await apiClient.getBytes(path);
final blob = web.Blob(
[Uint8List.fromList(bytes)], // ignore: argument_type_not_assignable
[Uint8List.fromList(bytes)] as dynamic,
web.BlobPropertyBag(type: mimeType ?? 'audio/mpeg'),
);
final blobUrl = web.URL.createObjectURL(blob);