Fix for new cast setup