Yes. If everyone became vegetarian, many people who depend on animal farming would have to find another way to earn a living.
Several centuries ago, the livelihoods and economic wellbeing of many people depended on the continuation of the slave trade. Nevertheless, the moral situation required that the slave trade be abolished, even though some people would have to find another way to make a living.
There is nothing new or unusual about an entire industry disappearing. For example, people who worked in horse-drawn transport had to find other jobs after cars were invented.