Lib: Update SubstitutionCard promises

This commit is contained in:
2025-03-27 12:59:01 +01:00
parent f66f6783d2
commit edbcf5e5ab

View File

@ -113,10 +113,10 @@
};
</script>
{#await Promise.all([data.graphics, data.drivers]) then [graphics, drivers]}
{#await data.drivers then drivers}
<Card
imgsrc={get_by_value<Driver>(drivers, "id", substitution?.substitute ?? "")?.headshot_url ??
get_driver_headshot_template(graphics)}
imgsrc={get_by_value(drivers, "id", substitution?.substitute ?? "")?.headshot_url ??
get_driver_headshot_template(data.graphics)}
imgid="headshot_preview"
width="w-full sm:w-auto"
imgwidth={DRIVER_HEADSHOT_WIDTH}