Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions lib/web_ui/lib/src/engine/canvaskit/fonts.dart
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ class SkiaFontCollection {
try {
buffer = await html.window
.fetch(url)
.then(_getArrayBuffer as FutureOr<ByteBuffer> Function(dynamic));
.then(_getArrayBuffer);
} catch (e) {
html.window.console.warn('Failed to load font $family at $url');
html.window.console.warn(e);
Expand All @@ -149,7 +149,7 @@ class SkiaFontCollection {
return actualFamily;
}

Future<ByteBuffer>? _getArrayBuffer(dynamic fetchResult) {
Future<ByteBuffer> _getArrayBuffer(dynamic fetchResult) {
// TODO(yjbanov): fetchResult.arrayBuffer is a dynamic invocation. Clean it up.
return fetchResult
.arrayBuffer()
Expand Down