The provisions of section 590.180 shall not apply to any elected or appointed sheriff of a* city not within a county.