forked from Nexus/nexus
Default to 1:1 when no width/height are given for an image
This commit is contained in:
parent
632c02a517
commit
7c01611859
1 changed files with 1 additions and 1 deletions
|
|
@ -19,7 +19,7 @@ class MessageImage extends ConsumerWidget {
|
|||
child: ClipRRect(
|
||||
borderRadius: .all(.circular(8)),
|
||||
child: AspectRatio(
|
||||
aspectRatio: info!.width! / info!.height!,
|
||||
aspectRatio: info?.width ?? 1 / (info?.height ?? 1),
|
||||
child: Image(
|
||||
image: CachedNetworkImage(
|
||||
url.toString(),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue