The rationale behind this is that with permanent residence there is the expectation of a careful examination of the dwelling, and that's relatively cheap because you only have to do it once every couple decades, whenever you buy a house, and hey, people should be able to make their house however they like. With temporary residence, the cost of doing that would be prohibitive, because visitors visit new temporary residences for short durations, and an individual visitor has a low probability of being hurt. Having a shoddy structure is the exact sort of thing where making decisions for immediate profit that have a low probability of high damages in the future that regulations make sense for.