Order confirmation email is not showing variant image [klaviyo template]

The confirmation, shipping, out for delivery and delivered emails are only showing the main product image, and not the variant images. I’m using the Klaviyo template for Confirmation Email.

I’ve attempted copying code from previous answers to a similar question, but none of them have worked.

The current code for the product images is:

{{ src="{{ line.image | product_img_url: 'medium' }}" }}

i’ve attempted these two alternate codes:

{% if item.product.variant.images.0.src %}{{item.product.variant.images.0.src}}{%else%}{{item.product.images.0.src|missing_product_image}}{%endif%}

and

src="{{ line | img_url: 'medium' }}"

Any advice on how to correct this?

Thanks!