forked from hans/Nominatim
When the address rank of an admin boundary is changed because of an attached place type, it may happen that the admin_level hierarchy gets inversed. Avoid that by adjusting the address rank if an inversion is detected.