Section 23
SEC. 23. Any justice of the peace or register of deeds who shall demand or accept, directly or indirectly, any gift, fee, commission or other form of compensation in connection with the service required to be performed by said justice of the peace as provided in section seventeen and by said register of deeds as provided in section eighteen of this Act, shall be punished by a fine of not more than one thousand pesos or by imprisonment for not more than one year, or both, at the discretion of the court.