Upon the hearing of such special proceedings the court shall find and determine whether the notice of the filing of the petition has been duly given and published for the time and in the manner in this act prescribed, and shall have power and jurisdiction to examine and determine the legality and validity of, and approve and confirm, each and all of the proceedings for the organization of said district under the provisions of said act, from and including the petition for the organization of the district, and all other proceedings which may affect the legality or validity of said bonds, and the order of the sale and the sale thereof. The court, in inquiring into the regularity, legality or correctness of said proceedings, must disregard any error, irregularity or omission which does not affect the substantial rights of the parties to said special proceedings; and the court may by decree approve and confirm such proceedings in part, and disapprove and declare illegal or invalid other or subsequent parts of the proceedings. The costs of the special proceedings may be allowed and apportioned between the parties, in the discretion of the court.
NMS § 73-9-59