
    Woodford et al. v. Kelley.
    1. Where defendant did not move to strike out specified portions of the complaint as irrelevant and redundant until after answer and the case had been called for the trial, the objection was waived.
    2. A complaint alleged that defendant, the owner of certain hay land, contracted that complainants should cut, press and haul the hay for a certain price; that under defendant’s directions and pursuant to such contract, plaintiffs cut and stacked a part of the hay and baled another portion thereof, but were prevented by defendant from baling and hauling all the hay required by the contract. Plaintiffs also alleged that they had expended a certain sum of money in the work, for which they claimed a lien on the hay not hauled, and alleged that defendant had wrongfully taken possession of the hay not paid for. and threatened to continue taking the same without paying plaintiffs’ claim. Held, that the complaint disclosed a joint enterprise or interest in the hay, warranting an accounting.
    3. The complaint also stated a cause of action warranting the appointment of a receiver pendente lite.
    4. Where a complaint is indefinite and uncertain, defendant’s remedy is by motion to make tne same more definite and certain, interposed before answer served, and not by an obj'ection at the trial that the complaint does not set out the contract specifically under which plaintiffs claimed their rights alleged.
    5. Under Rev, Code Proc. #311, providing that, where answer has been served, the court may grant the plaintiff any relief consistent with the case made by the complaint and embraced within the issue, the sufficiency of the complaint, when attacked at the trial by an objection to the introduction of any evidence thereunder, does not depend on the prayer for relief.
    6. Though plaintiffs’ complaint was inartistic, indefinite and uncertain, reversible error could not be predicated on the overruling of defendant’s objection thereto, first raised after the trial was begun by an objection to the introduction of any evidence thereunder, the case having heen heard on the merits, without apparent prejudice to defendant’s rights so far as the pleadings were concerned.
    7. Where plaintiffs contracted to cut, bale, and haul certain hay from defendant’s land, and they failed to bale and deliver a part of the hay as required by the contract, they were only entitled to recover the reasonable value of the work and labor performed, less the damages suffered by defendant on account of such failure.
    8. Where a contract provided for the payment of $200 as liquidated damages in case of a breach of the contract by either party, and plaintiffs, having failed to perform a part of the work required, sued for the reasonable value of the balance, it was not error for the court to allow defendant the amount fixed by the contract as liquidated damages to the exclusion of all othi r items of damage sustained by him, no question being raised regarding the validity of such liquidated damage clause.
    9. Where plaintiffs agreed to cut, stack, bale, and haul certain hay from defendant’s land, but, having failed to fully comply with the contract, sued for work and labor performed to defendant’s use, and there was no evidence showing the reasonable value of hauling part of the hay to a certain station, it was error for the court to allow plaintiffs the contract price therefor, they being entitled, under such circumstances only to the proved value of the work of cutting, stacking and baling the hay so hauled.
    30. Under the express provisions of Rev. Code Proc. § 146, a variance between the allegations of the complaint and the proof which does not actually mislead the defendant in making his defense on the merits'is immaterial.
    11. Rev. Civ. Code, § 2153, provides that every person who, while lawfully in possession of an article of personal property, renders any services to the owner thereof by labor and skill employed for the protection, improvement, or safe-keeping thereof, has a special lien thereon, dependent on possession, for the compensation, if any, due him from the owner for such services. Held that, where plaintiffs contracted to cut, stack, bale, and haul hay from defendant’s land, they were entitled to a special lien on the unhauled hay, dependent on possession, for their compensation, and, as between the parties, plaintiffs were in possession until the hay was voluntarily surrendered.
    12. Plaintiffs, being entitled to a lien on certain hay for their services in cutting, stacking and baling the same, within Rev. Civ. Code, § 2153, until such hay had been voluntarily surrendered, the appointment, of a receiver to preserve such lien in an action for work and labor performed under the contract was not error, though the appointment was not made until after defendant’s answer was served.
    13. Where plaintiffs were entitled to a • lien on certain hay, within Rev. Civ. Code, § 2153, for services rendered, dependent on possession of the hay, the fact that defendant was not insolvent did not deprive the court of authority to appoint a receiver to preserve such lien.
    (Opinion filed December 21, 1904.)
    Appeal from circuit court, Beadle county; Hon. J. H. McCoy, Judge.
    Action by George O. Woodford and another against C. A. Kelley. From a judgment in fayor of plaintiffs, defendant appeals.
    Modified.
    
      Kelley é Chamberlain and A. W. Wilmarth, for appellant.
    
      W. A. Lynch, for respondents.
   Haney, J.

The plaintiffs allege in their complaint,- in substance, that on August 10, 1901, the parties entered into a contract whereby they became jointly interested in the cutting, baling and shipping of hay; that by the terms of such contract defendant was to furnish certain hay lands, and plaintiffs were to cut, stack, and load the hay on cars, at stations named therein, at their own expense, and, when so loaded, were to receive for their labor and outlay $4 per ton; that plaintiffs, under defendant’s directions and pursuant to such contract, did cut and stack 425 tons of hay; that they baled about 90 tons, but were prevented by the defendant from baling and delivering all the hay required by the terms of the contract; that they expended $600 in doing what was done under the contract, for which they claim a lien on the hay not delivered; and that defendant has wrongfully taken possession of hay not paid for, and threatens to continue taking the same without paying what plaintiffs claim. They demand an'accounting, the appointment of a receiver, and such other relief as may be deemed equitable. Defendant admits in his answer having entered into a contract with the plaintiffs on the day alleged in the complaint; avers that such contract was in writing, a copy of which is set forth; denies that the parties had a joint interest in the hay; alleges complete performance on his part, and certain breaches of the contract by the plaintiffs. He further alleges by way of counterclaim, the payment of certain sums, damages caused by plaintiffs’ failure to perform, and demands judgment for $964.50. The reply denies all the allegations of the counterclaim except the payment to plaintiffs by defendant of $230.

After having answered, and when the cause was called for trial, defendant moved to strike out certain specified portions of the complaint as irrelevant and redundant. The motion was properly denied. Such a motion must be made before demurring or answering, or the right will be waived. Maxwell, Code Pleading, 2 362.

When the trial.began, defendant objected to the introduction of any evidence, for the reason “(1) that the complaint doos not state a cause of action, in that it fails to allege that the plaintiffs on their part have fulfilled the terms of the contract on which this action is based; (2) that the complaint does not set out the contract specifically, by which the court can ascertain whether the plaintiffs are entitled to recover thereon or not; and (3) that the complaint does not state facts sufficient to warrant plaintiff in the relief prayed for.” The objection was overruled. The ruling was based on the facts confessed by the objection, and must be considered with reference to the allegations of the complaint, uninfluenced by the terms of the written contract set forth in the answer. The first ground of objection is untenable, because, as we construe the complaint, it discloses such a joint enterprise and interest in certain personal property as warrants an accounting and appointment of a receiver pendente lite. The matter of performance is not involved, as it would be were plaintiffs merely seeking to recover damages for the breach of a contract. The second ground is clearly untenable. If the complaint was so indefinite or uncertain that the precise nature of the charge was not apparent, a motion to make it more definite and certain should have been interposed before the answer was served. As to the third ground: When thus attacked, the sufficiency of a complaint does not depend upon its demand for relief. In actions where answers have been served, the court may grant the plaintiff any relief ‘ ‘consistent with the case made by the complaint and embraced within the issue. ” Rev. Code Civ. Proc. § 311. If, upon all the allegations of the complaint most liberally construed, the plaintiffs were entitled to any relief whatever, defendant’s objection was not well taken. Such objections are not favored. Though the complaint is inartistic, indefinite, and uncertain, reversible error cannot be predicated on the overruling of defendant’s objection first raised after the trial began, the case having been heard upon the merits without apparent prejudice to defendant’s rights so far as the pleadings are concerned. Johnson v. Burnside, 3 S. D. 230, 52 N. W. 1057; Jenkinson v. City of Vermillion, 3 S. D. 238, 52 N. W. 1066; Wright v. Sherman, 3 S. D. 290, 52 N. W. 1093, 17 L. R. A. 792; Green v. Hughitt S. Tp., 5 S. D. 452, 59 N. W. 224; Townsend v. Kennedy, 6 S. D. 47, 60 N. W. 164; Anderson v. Alseth, 6 S. D. 566, 62 N. W. 435; Sherwood v. City of Sioux Falls, 10 S. D. 405, 73 N. W. 913; Martin v. Graff, 10 S. D. 592, 74 N. W. 1040; DeLuce v. Root, 12 S. D. 141, 80 N. W. 181.

On August 10, 1901, the parties entered into a written contract whereby it was agreed that plaintiffs should cut, stack, haul, and press the hay then growing on the south half of section 2-111-63, the south half of section 28-112-63, and the southeast quarter of section 17-112-62; the hay cut on the first two tracts when pressed, to be hauled and put on the cars by the plaintiffs, at Broadland or Wolsey, at the option of defendant; that cut on the other tract, when pressed, to be hauled and put on the cars, by the plaintiffs, at Broadland. They were to begin work within 10 days, and continue as long as the weather would permit or until the contract was completed, and were “to furnish not less than five carloads at each time at the different stations designated above, ” the defendant agreeing to pay $4 per ton free on board at stations named, said amount to be paid as follows: “Not over one-half the price of each car to be paid when loaded, balance payable immediately when contract is completed and hay loaded on cars. ” It was stipulated that, if the plaintiffs “failed to fulfill the terms of this contract, they will pay the said C. A. Kelley the sum of $200 as liquidated damages,” and that, if the defendant “fails to accept the hay according to the conditions of this contract, he shall pay to the said Pete E. McCray and George Woodford the sum of $200 as liquidated damages. ” The contract contains other provisions not material in this connection. The court below found that, in pursuance of this contract, plaintiffs cut and stacked 425 tons of hay; that, of the hay so cut, they baled and delivered 23 tons on board the cars at Broadland, and baled 80 additional tons ready to be delivered; that the cost of cutting and stacking was $1.25 per ton, and the cost of baling $1.50 per ton; that defendant has paid plaintiffs on account of the contract $299; and concluded, as matter of law, that “the failure of plaintiffs to bale and deliver said hay at stations, ready to be loaded on cars, was a violation of said contract, and m consequence they are only entitled to the reasonable value of the work and labor they performed in and about said hay, as found in the second finding of fact, less the damages suffered by defendant oa account of such failure, which is fixed by the contract at $200,” stating the account thus: To the credit of the plaintiffs: 23 tons delivered at Broadland, at $4 per ton, $92; 402 tons cut and stacked, at $1.25 per ton, $502.50; 80 tons pressed and baled, at $1.50 per ton, $120 — total, $714.50. To the credit of defendant: Cash paid to plaintiffs, $299; damages for failure to comply with contract, $200 — total, $499. Leaving a balance due the plaintiffs of $215.50, for which, with costs and disbursements, they had judgment, declared to be a lien on the hay in the hands of the receiver.

No question is raised concerning the sufficiency of the evidence to sustain the findings of fact,_ but defendant contends that the court erred in receiving evidence of the reasonable value of plaintiffs’ services, and allowing compensation for the same, when they failed to show a substantial compliance with the terms of the contract. There is, perhaps, no more vexatious question in the adjustment of the rights of parties to contracts than the determining what, if any, compensation may be recovered by a party to a special contract who has performed services or furnished materials not in strict compliance with the terms of the contract, but which have been accepted and utilized by the other party. By the strict rules of the common law, full performance was required as a condition precedent to the right of recovery; but the rigor of this rule has been relaxed in many jurisdictions, and the tendency is to administer equitable relief, rather than to hold the parties to the very letter of their agreement. Accordingly, when, under a special contract, the plaintiff has proceeded not in strict accordance with the stipulations of the agreement, yet if what he has done has been accepted and used by the defendant, it is held that the defendant is answerable for the benefit be has received on an implied promise to pay for the same, although no action can be maintained against him on the special contract. 9 Cyc. 687. Respecting contracts of employment, the modern equitable dotítrine has been adopted in this jurisdiction. Bedow v. Tonkin, 5 S. D. 432, 59 N. W. 222. In actions on builders’ contracts the rule of substantial compliance has been recognized. Hulst v. Benevolent Hall Association, 9 S. D. 144, 68 N. W. 200. This is not an action on a builder’s contract. If the contract be one of employment, the principles announced in the former case should prevail. If the relation of employer and employe does not exist, there seems to be nothing in our statutes or former decisions of this court to preclude the application of j ust and equitable principles. As heretofore suggested, this is not an action on the contract. The complaint was evidently drawn on the theory that each party had a joint interest in the hay, which should be sold to satisfy whatever sum was found to be due either party after an accounting. The decision below discloses that the hay belonged to the defendant; that plaintiffs contracted to cut, bale, and deliver it at certain specified stations for an agreed price per ton. It does not disclose the cause of their failure to complete the contract, but precludes us from ascribing such failure to the fault of the defendant. In the absence of evidence or findings to the contrary, we think it'should be presumed that plaintiffs were also without fault. So the case as established by the proof stands thus: Plaintiffs contracted to cut, bale, and deliver certain hay owned by the defendant. They partially performed, their contract, but, through no fault of either party, failed to deliver all of the hay. The cutting and baling of the hay was presumptively beneficial to the defendant. Under these circumstances, we think plaintiffs entitled to credit for the reasonable value of the benefits resulting to the defendant, less any payments for their labor, and any damages resulting from their failure to fully perform according to the terms of the contract.

No question being raised regarding the validity of the stipulations as to liquidated damages, the court did not err in allowing the amount provided for in the contract, which should exclude all other items of damage, and, as there is no dispute concerning the payments, defendant’s credits were properly ascertained. It did, however, err in allowing the plaintiffs the contract price for the 23 tons delivered at Broad-land. As the record does not show what it was worth to haul the hay to that station, the plaintiffs should only be allowed for cutting, stacking, and baling the hay so delivered, and, as it appears that such work was worth $2.75 per ton, they should have been allowed $63.25 for the hay delivered at Broadland, reducing the total of plaintiffs’ credits to the extent of $28.75. In all other respects the account was correctly stated.

It not appearing that the variance between the allegations of the complaint and the proof actually misled the defendant in making his defense upon the merits, such variance cannot be deemed material. Rev. Code Civ. Proc. § 146.

Plaintiffs were entitled to a special lien on the undelivered hay, dependent on possession, for the compensation due them from the defendant. Rev. Civ. Code, § 2153. As between the parties, they were in possession until it was voluntarily delivered, and, though the receiver was appointed after the answer was served, and defendant was not insolvent, the court did not err in preserving plaintiffs’ lien by the appointment of a receiver.

Except as modified herein, the judgment and orders appealed from are affirmed. Because of the slight modification, respondent should be allowed disbursements, but no costs should be taxed in favor of either party. The action is remanded with directions to modify the judgment as indicated herein.  