Code enforcement is an unrecognized but significant cause of homelessness. In one of my cases, two disabled brothers were put out of apartments twice by code enforcement authorities. It would have been better, in my opinion, for adult protective services - who were also involved - to have arranged home improvements and also arranged to have home health care services delivered to them.
Sadly, this did not happen.