<?php

$product = $args["product"];
$cart_item = $args["cart_item"];
$upsells = $args["upsells"];

foreach ($upsells as $id) {
  $up = new WC_Product($id);
  if ($up) {
    echo "<div>{$up->get_name()}</div>";
  }
}
