This is an action of ejectment to recover a strip of ground situated in the city of St. Louis, upon which the railroad of defendant is located.
Both parties claim under William T. Gay. At the trial in the circuit court the plaintiff' read in evidence a deed of trust, dated May 27th, 1874, and recorded May 29th, 1874, executed by William T. Gay and wife to A. M. Britton, trustee, to secure to plaintiff' a principal note of $29,000, due in five years, and ten semi-annual interest notes, all executed and delivered by said Gay to plaintiff, and of even date with the deed of trust, conveying a tract of land embracing the premises sued for; also the deed of William T. Gay and wife, by said trustee, dated June 8th, 1875, recorded June 9th, 1875, conveying to plaintiff, pursuant to a sale made under said deed of trust, said tract of land. Testimony was given by plaintiff tending to show “ that he never had actual notice, nor actual knowledge, nor actual information, that a railroad had been surveyed, or located, or in part or in any manner constructed upon the premises sued for, until his first visit to the premises, which occurred about three-weeks before June 8th, 1875.” The value of the monthly rents and profits and the amount of damages were established, and plaintiff rested his case.
The defendant gave in evidence a deed from William T. Gay and wife to the St. Louis & Elorissant Railroad Company, dated September 19th, 1874, recorded September 23rd, 1874, conveying in consideration of $1, the right of way for said railway, along and upon the premises sued for ; also documentary evidence showing that the defendant had succeeded to the rights of the St. Louis & Elorissant Railroad Company. Oral evidence was given on defendant’s behalf tending to show that in 1872 the St. Louis & *346Florissant Railroad Company surveyed and located its railroad upon the premises sued for with the verbal permission of William T. Gay, and subsequently in 1873 the right of way across said premises for said railroad was conveyed by deed of said Gay to said company; said deed, however, was never recorded and was lost, and the deed of September 19th, 1874, read in evidence, was in lieu thereof. In 1873 some grading was done by the company along the line of the railroad and upon the premises sued for. The work was suspended in that year by reason'of the panic, and in 1874 the last work on the road bv the St. Louis & Florissant Railroad Company was performed, and said corporation became insolvent, and in January, 1875, its property, etc., was sold under a mortgage dated August 20th, 1874, and purchased by Lionberger, and by him conveyed to the defendant February 1st, 1875, and in 1875 defendant entered and commenced work upon the premises in question, and put in culverts and erected trestle work and finished the embankment and laid the iron and ties, so that upon May 29th, 1875, the first construction train, and on June 12th, 1875, the first passenger train passed over the premises, and thereafter defendant fenced in the premises. The plaintiff never objected to defendant’s operations until about a month after the cars commenced running, when he demanded payment for the land in dispute.
It does not plainly appear when the road was completed so as to be ready for the cars, nor does it appear when the default occurred in the payment of the notes made by Gay to the plaintiff, for which the land sued for was sold by the trustee, Rritton.
The circuit court rendered judgment for the defendant, which was reversed by the court of appeals, and the defendant has appealed to this court. The court of appeals held that as the plaintiff took the trust deed without notice, actual or constructive, of the rights of the Florissant Railroad Company, to which the defendant succeeded, he was entitled to recover, and that the facts stated in the *347record did not bring the defendant within the rule laid down in Provolt v. Railroad, 57 Mo. 256, and Baker v. Railroad, 57 Mo. 265. In this opinion we fully concur; but as the case is to be retried, we think it proper to add a few observations upon the latter point.
It is very clear that none of the acts done by the railroad company upon the land sued for, prior to default in the payment of the debt, or interest, secured by the trust deed, called for any action on the part of the plaintiff, who was the beneficiary in said deed, even if he had known of them. Prior to the default of the mortgageor, the mortgagee had no right to forbid the mortgageor or his licensee, from doing any work on the mortgaged premises, which did not impair the value of the land as security for the debt. If it clearly appeared, however, that after the trustee, by reason of default in the payment of any of the interest notes, became entitled to take possession of the land for the beneficiary, the defendant’s road was in process of construction and not completed, and the plaintiff had knowledge that the defendant was building its road under a parol license, or an unrecorded deed given or made prior to the default, we think it would have been the duty of the plaintiff' to have notified the defendant that there had been a default in thepayment of the notes, and that he was entitled to the possession of the land and forbade the further prosecution of the work. This duty results, as we think, from the nature of the estate of the mortgagee. A mortgage, in this State, is a mere security for the debt, and notwithstanding the legal title is nominally in the mortgagee, the mortgageor is still considered the owner and entitled to the possession until default. Woods v. Hilderbrand, 46 Mo. 284. Such being the law, we do not think it would be equitable to permit a mortgagee to lie by after the default of the mortgageor, and see a valuable and costly improvement erected upon the mortgaged premises, by a third party, in good faith, under a license from the owner of the land, making no objection whatever, and when the structure *348is completed, deprive such party of its enjoyment. In such case, we think the license of the owner should be held to be the license also of the mortgagee.
The judgment of the court of appeals will be affirmed, aud the cause remanded to the circuit court for a new trial.
All the judges concur.