fixes to unfolding