Any person holding a miner's lien may foreclose the same in the same manner as a construction lien may be foreclosed. In an action for the foreclosure of such lien, each person claiming a lien upon the property charged must be made a party to the action, and the rights of all parties must be determined by the court and such order made in regard thereto as shall preserve and protect the rights of all parties.
N.D.C.C. § 35-15-06