“Mayor” when used with reference to a county means the chairman of the board of supervisors, and when used with reference to a city means the mayor, or if the city has no mayor, the chairman or the president of the legislative body, the city manager or such other person as may be the chief executive officer of the city.