Spalding, J.
This action was tried by the court, and is here ' for tnal de novo. The defendants had'judgment, and plaintiff appeals. It is an action brought to foreclose a mechanic’s lien upon lots 17 and 18, in block 3 of Chess & Lloyd’s addition to the city of Fessenden, Wells county, N. D. The evidence is conflicting as to some facts, but, as we regard it, these conflicts are of no importance. Our decision must be based solely upon questions of law.
As far as material to our decision, the facts appear as follows: Title to the lots described stood in defendant Mark Hunt. He had deeded the same to his mother, the defendant Henrietta C. Hunt, but the deed had never been recorded. Henrietta C. Hunt entered into a contract with one Weseman for the erection of a dwelling house on the lots mentioned for the sum of $2,027. Weseman was to furnish all the material and labor necessary to complete the construction of such dwelling. Between the 4th day of June and the 15th day of November, 1906, the contractor purchased lumber and building material from appellant, the plaintiff herein, amounting in the aggregate to the sum of $1,147.60. Some articles were returned, reducing the amount to $1,092.65, and since this action has been brought other articles have been returned which appellant concedes may be credited, reducing the total debt to $1,084.70, no part of which has ever been paid.. No question is made as to all of such lumber and material being used in the erection of the dwelling house and a considerable portion, of it was used by respondents in completing it. The testimony is in con*436fiict as to when the defendant Henrietta C. Hunt first knew that the plaintiff was furnishing any material to Weseman, but she admits that she did know it on the 31st day of October, 1906. Weseman proceeded on the contract until the superstructure was erected, inclosed and plastered and some of the other inside work done, when he abandoned it. It is not claimed that he notified any of the parties that he was about to or had abandoned the contract. Respondent had paid Weseman $1,013.50, the last payment having been made on the 15th day of September, 1906. The date of the abandonment is not definitely fixed, but it is reasonably certain that it occurred between the 14th and 24th days of November, 1906. On the latter date, appellant sent respondent Henrietta G. Hunt a registered letter, as required by section 6237, Rev. Codes 1905, notifying her that it had furnished the material in question to- the contractor for use in her dwelling house, and on the 7th day of December, 1906, a similar notice was sent by registered letter to the respondent Mark Hunt. Nothing was done by respondents toward completing the structure until after such notices were received by them and the lien filed. On the 8th day of December, 1906, appellant filed in the office of the clerk of the district court in and for Wells county the verified account, necessary to perfect a mechanic’s lien against the premises for which the material was furnished. Thereafter notice was given to appellant demanding that suit be commenced to enforce such lien, whereupon this action was instituted.
This court has already held that the mechanic’s lien law, under which this lien is claimed, must be classified as belonging to the Pennsylvania system, as distinguished from the New York system, and that the subcontractor is entitled to a lien irrespective of the state of accounts between the owner and the contractor, or the amount due or unpaid upon their contract. Robertson Lumber Co. v. Bank, 14 N. D. 511, 105 N. W. 719. In the same case it was held that the owner must keep advised whether the material used in his building is paid for or not, and, if he pays the contractor during the ninety days after the material furnished, he does so at his peril. Section 6237, Rev. Codes 1905, reads as follows: “Any person who shall perform any labor upon or furnish any materials, machinery, or fixtures for the construction or repair of any work of internal improvement or for the erection, alteration or repair of any buildings or other structures upon land, or in *437making any other improvements thereon, including fences, sidewalks, paving, wells, trees, grades, drains or excavations under a contract with the owner of such land, his agent, trustee, contractor or subcontractor, or with the consent of such owner, shall upon complying with the provisions of this chapter, have for his labor done, or materials, machinery or fixtures furnished, a lien upon such building, erection or improvement and upon the land belong-, ing to such owner on which the same is situated or to improve which the. work was done, or the things furnished, to secure the payment for such labor, materials, machinery or fixtures; provided that no person who furnishes any materials, machinery or fixtures as aforesaid, for a contractor or subcontractor, shall be entitled to file such lien unless he notify the owner of the land by registered letter previous to the completion of said contract that he has furnished such materials, machinery or fixtures. The owner shall be presumed to have consented to the doing of any such labor, or the making of any such improvement, if at the time he had knowledge thereof, and did not give notice of his objection thereto to the person, entitled to the lien. The provisions of this section and chapter shall not be construed to apply to claims or contracts for furnishing lightning rods or any of their attachments.” It will be noticed that the foregoing section requires the notice by the materialman to be given to the owner previous to the completion of his contract by the contractor. The trial court evidently held that the naked abandonment of the contract or work, under this statute must be construed as a completion of such contract, and that, the appellant not having notified respondents that it was furnishing materials to Weseman until a few days after such-abandonment, no lien could be sustained. This is in accordance with the contention of respondents, while appellant insists that under the Pennsylvania system the mere fact of a contractor abandoning the contract when partially completed does not of itself work a completion of the contract. We must hold that the trial court erred in its construction of the law and that the abandonment by the contractor of the contract when a substantial portion of it had been executed does not work a completion of the contract. The mechanic’s lien law is designed to protect materialmen and laborers, and should be liberally construed to effectuate this purpose. Salzer Lumber Co. v. Clafiin, 16 N. D. 601, 113 N. W. 1036. Among the things which a contractor engaged on a losing contract is liable *438to do at any time is to abandon the same, and protection against this, in the interest of the materialman or subcontractor, is' one of the most essential elements entering into the mechanic’s lien law, and is among the purposes for which it was enacted. In the absence of a specific provision of the statute on the subject making the execution of the contract complete when abandonment occurs, we cannot assume that the law contemplates such a result. There are two lines of authorities on the subject, but we discover none sustaining the contention of the respondents except those construing statutes held to be in conformity with the New York doctrine. Those which are held to harmonize with the Pennsylvania system hold to the contrary, with the possible exception of some wherein the subject is covered by the statute itself. We are cited California authorities and others; but the statute in California expressly provides that the contract is terminated by its abandonment. The subcontractor in this state is entitled to a direct lien for work done or materials furnished to the contractor, and in states where a direct lien is given the failure of a contractor to complete his contract does not destroy the subcontractor's lien. Boisot on Mechanics’ Liens, section 236; 21 Cyc. pp. 100, 101, and cases cited; Red River Lumber Co. v. Congregation of Israel, 7 N. D. 46, 73 N. W. 203.
(122 N. W. 865.)
It follows from what we have said that the notices by registered letter were sent to the respondents seasonably, and that their property must sustain the burden of the lien in question. All other questions hang upon the one as to whether the contract was completed by the abandonment. Hence they need not be noticed.
The judgment of the district court is reversed, and it is directed to enter judgment of foreclosure in accordance with this opinion.
All concur, except Morgan, C. J., and Ellsworth, J., not participating.