NAND wasn't ever a big and profitable biz for Intel.
Its also really cyclical so people could look at today and say "look at Samsung's earnings, Intel was stupid to get out of NAND" but look at Samsung's earnings in the last year or two before that and you see why it was smart for Intel to get out. They didn't have to scale to compete against the remaining behemoths in the NAND market, and Chinese suppliers are going to make things painful in the long run.
NAND is a commodity so even if western markets are somewhat protected against them via tariffs and other trade barriers that Chinese NAND is going to put pricing pressure on them and prevent the memory cartel from "agreeing but not agreeing" to cut back production at the bottom of the cycle.