I don't think Tucson believes that's a mistake. Cities would prefer that all buildings are up to code, all the time. Tucson was lenient enough to say that if your friend can afford to keep the building dark for six months, he can afford to bring it up to code. It's entirely likely that if he tried to insure the building, his insurance company would require an inspection and similar work.
Perhaps he needed better inspection before purchase.