No ordinance granting such franchise, or extension or renewal thereof, shall be valid unless it shall expressly provide therein that the price to be paid by the city for the property that may be acquired by it from such utility by purchase, condemnation or otherwise, shall exclude all value of such franchise, extension or renewal, except that, unless otherwise provided in such ordinance, the utility shall be entitled to the return of the proportionate amount for the unused period of any compensation paid to the city for such franchise, extensions or renewal.