Any city of the first class may, by ordinance, extend, upon conditions deemed proper, the provisions of retirement and pension systems for superannuated and disabled officers and employees to officers and employees with five years of continuous service and acting in capacities in which they would otherwise not be entitled to participation in such systems: PROVIDED, That the following shall be specifically exempted from the provisions of this section.
(1) Members of the police departments who are entitled to the benefits of the police relief and pension fund as established by state law.
(2) Members of the fire department who are entitled to the benefits of the firefighters' relief and pension fund as established by state law.