2
0
mirror of https://github.com/inventree/inventree-app.git synced 2025-04-28 21:46:46 +00:00

Make height / width nullable for getImage

This commit is contained in:
Oliver 2021-07-13 00:29:07 +10:00
parent 5728d1e698
commit 3c6039f757

View File

@ -866,7 +866,7 @@ class InvenTreeAPI {
* Load image from the InvenTree server, * Load image from the InvenTree server,
* or from local cache (if it has been cached!) * or from local cache (if it has been cached!)
*/ */
CachedNetworkImage getImage(String imageUrl, {double height = 0, double width = 0}) { CachedNetworkImage getImage(String imageUrl, {double? height, double? width}) {
if (imageUrl.isEmpty) { if (imageUrl.isEmpty) {
imageUrl = staticImage; imageUrl = staticImage;
} }