New solution for recycling of rare earths