delivered the opinion of this court.
The record in this case shows, that the endorsement by the defendant of Pyfer’s notes to the plaintiff was based upon the security afforded by the mortgage, and therefore the mortgage may be regarded as the consideration of the agreement into which the surety entered when he consented to endorse the notes. The terms of the mortgage, therefore, must be strictly complied with by the plaintiff in order to bind the defendant as endorser. One of those terms is, there shall be no sale of the mortgaged property until default of the principal debtor to pay the uotes upon their maturity. We think this part of the contract between the several parties thereto has been departed from in the sale which has taken place, under the circumstances detailed in the evidence. This sale took place before the maturity and dishonor of the notes in question, and without the assent, and, for all we know, without the knowledge, of the endorsers. It is true the first of the original notes had fallen due and was dishonored, but it is equally true, by the assent of all parties, another note was substituted in the place of it, which thereby took from the plaintiff his right to seii under the mortgage for the non-payment of that note: — the effect of the substitution of the one note for the other was to place the new note in the same relation to the mortgage that the first one had borne. Before these notes became due, as we have already shown, the sale took place.
But it may be said, that although this might have been a departure from the strict letter of the contract between the parties, yet it cannot bo shown that the endorsers were preju*110diced thereby or their liability enlarged. Whether this was or was not the result of the premature sale, does not vary the question. Any dealings with the principal debtor by the creditor which amounts to a departure from the contract by which a surety is to be bound, and which by possibility might materially vary or enlarge the latter’s liabilities without his assent, operates as a discharge of the surety. In this case it is not improbable, much less impossible, that if the plaintiff had duly protested the first two notes as they fell due and were dishonored, the endorsers, or one of them, might have paid them off, and by immediately suing the debtor thereon might have secured the debt and thereby reserved the whole of the mortgaged property in the hands of the plaintiff for the purpose of meeting the third and last note upon its maturity. The sale of the mortgaged goods, under the circumstances under which it took place, deprived the endorser of the opportunity of pursuing the course we have pointed out, and of the chances, at least, of relieving himself from liability altogether.
Believing that the sale of the property under the circumstances was a violation .of the terms of the contract with the endorsers, by which their rights might have been prejudiced, they are thereby discharged.
Judgment affirmed.