Unfortunately, that rewrite step often doesn't happen. I can't count the number of times a prototype that was meant to be thrown away was actually put into production because "it's cheaper and faster than rewriting."
I have no idea who said that, but I use it a lot at work when people want to cut corners with the intent to fix it later.
Did the business make money, though? I think that's the law of the jungle