Opinion of the Court by
Affirming.
The appellees, J. A. Wood & Co., had purchased In and around East St. Louis, Ill., 25 mules, which, they placed in the hands of Pendleton & Co. to be shipped to Charlestown, W. Va. Pendleton & Co., as agents of appellees, entered into a contract with the appellant, Baltimore & Ohio Sothwestern Eailroad Company, by which it agreed to carry the mules to their point of destination. The contract made by Pendleton & Co. with appellant was in writing, and is contained in the hill of lading filed as an exhibit with an amended answer of appellant. In pursuance of this contract, the appellant took charge of the mules and carried them in its cars, first, to Cincinnati, Ohio, where they were unloaded and fed 200 pounds of hay. They were then reloaded and carried to Athens, Ohio, which was the end of appellant’s line, and there the ears containing *842the mules were delivered to a connecting carrier, which transported them to their point of destination, Charlestown, W. Ya., and delivered there to the consignee, A. Wood & Co. When- first unloaded, the mules, appeared to be in fairly good condition, but within a few hours three of them died. Whereupon appellees, Wood & Co., instituted this action against appellant, the initial carrier, alleging in substance that the mules had been neglected by the carrier; that it had, in violation of the federal statute regulating the matter* kept them on board its cars without food, water, or rest for more than 28 hours; that when it did feed them at Cincinnati it only gave them eight, pounds of hay, each,-' and that during the whole trip, which required four or five days, the mules were only fed, watered, and rested once, and at this time they were very insufficiently fed; that, by reason of this neglect and want of care, the mules had been weakened and injured, and three óf them died in consequence ; that these three were reasonably worth $430, for which judgment was prayed. The action was not founded on the written contract, but the petition alleged an oral agreement, which may be said to have differed widely from the terms of the bill of lading, although we do not find it necessary to examine the question of difference here. In the answer the defendant (appellant) denied the existence of the oral contract between it and appellees, and all negligence or want of care on its part in the transportation of the mules, pleaded the existence of the written conract which it claimed regulated the terms of its liability in the transportation of the mules-, and, further, that under its terms it was only liable for such injury as occurred to the mules by reason of its negligence while they were being transported over its lines, and that *843its responsibility for the safety of the mules ended at Athens, Ohio, where they were delivered to the connecting carrier. The plaintiffs (appellees) by reply denied the existence of the'written contract, and alleged affirmatively that Pendleton & Co. had no authority to make such a contract on their behalf. This substantially completed the issues between the parties, and a trial by jury resulted in a verdict in favor of the plaintiffs (appellees) for the value of the mules as alleged in the petition, $430.
The appellant complains on appeal that the court erred in overruling its motion for a peremptory instruction made at the close of the evidence; and this, position is based upon the fact that there was a total failure of evidence on the part of appellees to establish the alleged oral contract which constitutes the basis of the petition, and there was therefore a fatal variance between the allegations of the pleadings and the proof adduced to support them. Undoubtedly the appellees did fail to establish the existence of the oral contract because they failed to show that the party with whom the contract was made represented in any way the railroad company; and it is equally true that at common law the variance which occurred between the allegations of the petition and the proof would have entitled the appellant to a peremptory instruction to find a verdict in its favor. But the common-law rule on this subject has been changed by the Code, the object being to abrogate its harsh technicalities and to do substantial justice between the parties litigant; and for this purpose a new rule is provided, the object of which is not, as at common law, to baffle or per.plex justice by an immaterial variance, but to do substantial justice between the parties according *844to the very right of the case. The sections regulating this matter are:
“Section 129. No variance between pleadings and proof is material, which does not mislead a party, to his prejudice, in maintaining his action or defense upon the merits. A party who claims to have been so misled must show that fact to the satisfaction of the court; and, thereupon, the court may order the pleading to be amended, upon such terms as may be just.
“Section 130. If such variance be not material, the court may direct the fact to be found according to the .evidence, and may order an immediate amendment.”
Now, it is evident that in the case before us the defendant was not misled to its prejudice, or at all, by the variance between the oral contract sued on, and the written contract proved, because it pleaded the written contract as regulating its liability, and this much of its defense was upheld by the trial court. It can not, therefore, complain that the court took its view of this issue. The very question we have here arose in Illinois Central R. R. Co. v. Curry, 127 Ky. 643, 106 S. W. 294, 32 Ky. Law Rep. 515, and in the opinion the authorities construing the sections of the Code, supra, were all reviewed. In that case, as in this, the plaintiff sued on an oral contract for damages to stock by the common carrier, and the defendant pleaded a written bill of lading limiting its liability. It was there claimed, as heré, that there was a variance between the pleading and the proof, because of the failure to establish the oral contract. But it was held that the fact that the plaintiff alleged an «oral contract, which the defendant denied and pleaded a written contract, was not a material variance if the defendant sustained its side of that controversy and the plaintiff *845failed to establish the oral contract sued on. And under the sections of the Code above cited, this position is sound. The foundation of the plaintiff’s action here is the negligence of the carrier in transporting the stock. The two contracts contended for by the respective parties to the litigation present two different rules of liability; but the defendant may be liable .under either if the facts showing the negligence sustain it. There is no difference in the contention of the respective parties. The only benefit which the defendant could hope for by establishing the existence of the written contract lay in its being able to show that the injury complained of occurred upon the line of the connecting carrier; but this benefit is entirely dissipated if the facts show that the injury occurred in whole or in part on its line and by the negligence of its employes. This would have been different if the injury had been shown to have occurred wholly upon the line of the connecting carrier, because then there would have been a total failure of proof within the meaning of section 131 of the Civil Code of Practice. But, unfortunately for the defendant, the facts did not show that the injury occurred upon the lines of the connecting carrier. On the contrary, if plaintiff’s evidence is true, a very large part of the injury, if not all of it, occurred on the line of the defendant company. The court in its instructions presented this view of the case. It was first held that there was a failure of evidence to establish the oral contract, and the. jury were so instructed. Then they were instructed that the liability of the defendant must be regulated by the' written contract or bill of lading. Now, as said before, this was entirely favorable to the defendant, and it can not be heard to complain that the court decided in its favor the very thing it desired to be established. *846It could not say that it was surprised or misled by the establishment of the written contract because this was precisely what it had undertaken to establish.
Moreover, if the variance had been one which misled the defendant to its prejudice,- it would have been its duty to call the court’s attention to it at the time of the trial, and then, under the provisions of the Code cited, the court, would, in aid of substantial justice, have required such amendments in the pleadings as were necessary to make them conform to the proof, and, if justice required it, granted the defendant a continuance of the case in order to • permit proper time and opportunity for it to prepare its defense to meet the new or modified issues. But there is nothing of that sort in this case. . Here the parties disagreed as to whether the contract of shipment was written or oral, and, when the court held that, under the evidence, the defendant’s position on this subject was sustained, it required plaintiff’s cause of action to be measured by the defendant’s liability for negligence under the bill of lading. Section 134 of the Civil Code of Practice, to which great force ought always to be given, provides, among other things: “The court must in every stage of an action disregard any error or defect in the proceedings, which does not affect the substantial rights of the adverse party; and no judgment shall be reversed or affected by reason of such error or defect.” When the trial court limited defendant’s liability for injury to the stock to that which occurred on its own line, substantial justice was done to it under the facts of this case; and any other rule would enable the defendant to escape-merited liability upon technicalities based upon the' mistakes of the plaintiff as to immaterial matters. The trend of the science of pleading is away from barren teckni*847calities and towards the enforcement of rules which will administer justice according to the very right of the case.
Appellant also contends that it was entitled to a peremptory instruction because there was no allegation in the pleadings or evidence upon the trial of a-consideration for the eontract to carry the stock. It may be true that the plaintiffs failed to állege specifically a consideration for the undertaking of the defendant before the motion for a peremptory instruction was entered, but after this motion was made the court allowed plaintiffs to amend their petition so as to allege the consideration; and this, we think, was allowable by the rule which permits the trial court a wide discretion in the matter of amendments in order that substantial justice may be done. Appellant also overlooks the fact that it pleaded the bill of lading as the contract between the parties, and filed it as an exhibit with its amended answer. This bill of lading shows the consideration for the transportation of the stock to have been $83, and, while an exhibit may not avail to support the pleading of the party who files it, if it lacks a necessary allegation, it will avail the adverse party to supply anything omitted which would have been to his advantage. Both plaintiffs, Fox and Wood, testified positively that they paid the defendant carrier for transporting the stock. The agreed facts show that the mules were on the train of the defendant for 36 hours before they were unloaded, fed, or watered; that they were in its possession between the time they were shipped from East St. Louis until they were delivered to the connecting carrier at Athens — 59 hours — during which time they were given but eight pounds of hay each. The evidence for the plaintiffs warrants the conclusion that the stock was *848very much weakened and injured by this long fast, and that the death of those whose value is sued for was superinduced or caused by this mistreatment. The shipment was interstate commerce, and the federal statute (section 4386, U. S. Rev. St.-[U. S. Comp. St., 1901, p. 2995]) provides the'duty of the carrier to the stock en route. It requires the carrier to unload live stock, feed,' water, and rest it at least once in every 28 hours. This statute was flagrantly disregarded by the appellant, and there can not be any reasonable doubt, from the evidence in this case, that the mules were much weakened and injured by the failure of the appellant to comply with the provisions of the statute. The plaintiffs’ evidence also tends to show that eight pounds of hay is insufficient food for a mule during so long a period of time; and, as said before, there was testimony tending to show that so long a fast would so weaken the animals as to render them liable to disease, which, otherwise, would not affect them.
The court instructed the jury as follows:
“(1) The law made it the duty of the defendant company during the.time it had the mules in its possession as carrier to rest, water, and feed the same at least once in 28 hours, not longer without such watering, feed, and rest than 28 hours, and at the end of the period of 28 hours the mules should be rested for a period of at least 5 hours, and for this purpose should be taken from the car. It appears from the evidence in this case that the mules were not fed until after they arrived at Cincinnati and about 38 hours, after their shipment and at that time were fed about 200 pounds of hay. Now, if you shall believe from the evidence that the mules in question by reason of the failure of the defendant company to teed them *849within 28 hours and of their failure to feed the mules until 38 hours had elapsed after their shipment or because said mules were not then fed sufficiently, if such- be the fact, the three mules in the evidence referred to were made sick and that by reason of thie sickness so brought about they died, or if the jury shall believe from the evidence that the failure of the defendant company to feed the mules within 28 hours or to sufficiently feed them co-operated or concurred with a subsequent like failure on the part of the connecting carrier in causing the death of the mules, then the law is for the plaintiff, and the-jury should so find.
“ (2) But unless the jury shall believe from the evidence that the death of the three mules in the evidence referred to was caused by the failure of the defendant company to feed the mules within the 28-hour limit or its failure to feed them at all until about 38 hours had elapsed, or their failure to sufficiently feed them, if such be the fact, or that such failure upon the part of the defendant co-operated and concurred with a. subsequent like failure on the part of the connecting carrier in causing the death of said mules, the law is for the defendant, and the jury should so find.
“ (3) If .the jury shall find for plaintiffs, they should find'for them in such a sum as they shall believe from the evidence will represent the fair market value, of the three mules in question that died at the time of their death in Charlestown, W. Va., not exceeding $430, the amount claimed in the petition.”
The appellant complains of-the foregoing instructions in so far as they make it liable for the whole value of the mules which died, although only a part of the injury which caused their death occurred upon its lines. This complaint is based upon an unsound view of the law regulating the point in question. If *850the death of the mules was caused at all by what hap^ pened upon the train while they were en route, this cause was starvation; and, while it is possible that so much of the starving process which occurred on the line of the appellant may not alone have caused the mules to die, it is an elementary principle that, where injury is caused by the joint negligence of two or more wrongdoers, each is liable for all the injury. The complainant is not required to segregate the injury into parts. He may sue one or all of the joint wrongdoers and recover his whole damage from one or all at his election. And therefore the court properly told the jury that, if the negligence of the appellant concurring with the joint negligence of the connecting carrier caused the damage, appellant was liable for it all at the suit of appellees.
Judgment affirmed.