For some reason, it has recently been a common theme that it is illegal/unethical/immoral - make your choice of evil - to purchase a property and sell it for a profit. I do not know why this has suddenly become an issue. Investors have been buying property and selling for a profit for years.
Ironically enough, many lenders and the federal government have loosened restrictions on "flipping" or "wholesaling" real estate. So, I am at a loss to explain why this is happening.
Additionally, investors who buy and re-sell for a profit, make up a significant number of homes being sold today. Numbers vary from 17%-30% of homes sold are by investors who seek to make a profit. Without them, the current housing market would be exponentially worse than it is now. When you consider that shadow inventory currently is 30 months, it would be catastrophic for investors to leave (or be regulated out of) the real estate market.
Flipping and wholesaling will be a reality as long as real estate is bought and sold and there are many ways to flip or wholesale properties legally. Unfortunately, many have abused the system and given such practices a bad name.