There’s a thin line between equity and debt: affiliates, advances and avoiding recharacterization