Based on that logic, layoffs should sometimes cause the stock of a company to go down, if the shareholders think those employees contributed more value than the company saves by laying them off.
In reality layoffs almost always cause the stock to go up. The market seems to think layoffs are an unalloyed good.