delivered the opinion of the< Conrt.
This suit, standing on hill of complaint of the city and cross bill of the railway company, was brought to determine whether the city or the company is liable for the cost of constructing a bridge over the track of the company on one of the streets of the city.' The bridge, being deemed by both parties an urgent necessity, was constructed at a cost of $8,354.90, under an agreement that provided that each party should contribute one-half of the cost, and that neither should be precluded of its right later to recover of the other. The city sues for $4,177.45, and the company by its cross bill sues the city for a like sum.
The city predicates its right to recover on an ordinance duly passed pursuant to power conferred on it *401by an act of the legislature (Acts 1907, cb. 149-, sec. 250 “to require, by ordinance, railroad companies to build, maintain, repair, or replace, at tbeir own expense, sncb bridges, and approaches, . . . over tbeir tracks when the same cross ary of the streets of said city, as the general council may deem necessary to the safety and convenience of the public traveling on said streets,” etc.
The bridge in question replaced an old wooden structure which bad been erected in 1876, and, concededly, bad become inadequate.
The company.’s defense, and also its right to recover under its cross bill, is, in the ultimate, b,ased on a contract in reference to the construction of the old bridge; it being alleged that-in 1876 its predecessor company bad contributed $1,000 towards such construction under a contract, duly entered into, which provided that for'that consideration the city should build and forever afterwards maintain a bridge at the crossing in question, sufficient and suitable to accommodate the travel at that and all future times. It is contended by the company that this contract was validly entered into, and that it cannot be affected by the statute and the pursuant ordinances, later passed, because of the provision of the constitution of the United States (article 1, sec. 10) forbidding the passage of laws impairing the obligation of contracts.
It is clear that the statute and ordinance touching such bridge were within the scope, and an exercise, of the police power of the State. Authorities subsequent!
*402Bnt the company’s contention is that, while this may he true generally, yet that the extension of the police power of the city by the legislative act could not operate ■ to nullify the contract previously made, especially since ' the city does not purpose a change in the character of the crossing from an overhead structure to one not overhead.
The insistence of the city is that it was beyond the power of the board of mayor and aldermen of Chattanooga, in 1876, to so bargain or contract as to deprive future boards of the exercise of police power in relation to this subject-matter, thereafter conferred on the municipality by the State.
No court has gone further than the supreme court of the United States in giving to the .police power a broad scope and application. Chicago, etc., R. Co. v. People, 200 U. S., 561, 26 Sup. Ct., 341, 50 L. Ed., 596, 4 Ann. Cas., 1175.
Recent decisions by that court appear to us to have construed the provision of the national constitution invoked by the company — forbidding the impairment of the obligation of contracts — in connection with the police power, in such way as to demonstrate the unsoundness of the company’s contention.
In Chicago, etc., R. Co. v. Nebraska, 170 U. S., 57, 18 Sup. Ct., 513, 42 L. Ed., 948, it was held that contracts which affect the safety and welfare of the public are within the supervising power and control of the legislature when exercised under the police power to protect the public safety, and that the obligation of a con*403tract between a city and a railroad company to participate, in view of their mutual duty to the public, in the construction of a viaduct over the company’s tracks is not violated or impaired by a statute and ordinance, later passed, compelling the railroad alone to repair it. The court, speaking first in respect of the contract to participate in the construction of the viaduct, said:
“No doubt the agreement of 1886 constituted a contract in such a sense that the respective parties thereto •continued to be bound by its provisions so long as the legislation, in virtue of which it was entered into, remained unchanged. While the agreement lasted, its provisions defined the rights and duties of the city and the railroad companies. But was it a contract whose continuance and operation could not be affected or conT trolled by subsequent legislation?
“Usually, where a contract, not contrary to public policy, has been entered into between parties competent to' contract, it is not within the power of either party to withdraw from its terms without the consent •of the other, and the obligation of such a contract is ■constitutionally protected from hostile legislation. Where, however, the respective parties are not private persons, dealing with matters and things in which the public has no concern, but are persons or corporations whose rights and powers were created for public purposes by legislative acts, and where the subject-matter •of the contract is one. which affects the safety and welfare of the public, other principles apply. Contracts of the latter description are held to be within *404the supervising power and control of the legislature when exercised to protect the public safely, health, and morals, and that clause of the federal 'constitution ’ which protects contracts from legislative action cannot in every case he successfully invoked. The presumption is that, when such contracts are entered into, it is with the knowledge that parties cannot, by making agreements on subjects involving the rights of the public, withdraw such subjects from the police power of the legislature.
“We do not, indeed, understand that these principles are questioned on behalf of the plaintiff in error. What is claimed is that the. subject-matter of the contract in question does not fall within the range of the police power of the State; . . . that, while it is not questioned that the maintenance of the viaduct is essential to the safety of the community, yet, if existing contract obligations devolve this burden upon the city, the legislature of the State cannot, under the plea of public necessity, pass a law imposing it upon the plaintiff in error, without bringing the act within the prohibitions of the'federal constitution.”
Continuing the discussion on the point pressed on us in the case in hand, the court said:
“In view of the paramount duty of the legislature to secure the safety of the community at an important crossing within a populous city, it was and is within its power to supervise, control, and change such agreements as may be from time to time entered into between'the city and the railroad company in respect to *405such crossing, saving any rights previously vested. Any other view involves the proposition that it is competent for the city and the railroad company, by entering into an agreement between themselves, to withdraw the subject from the reach of the police power, and to substitute their views of the public necessities for those of the legislature.”
In State, ex. rel., Minneapolis v. St. Paul, etc., R. Co., 98 Minn., 380, 108 N. W., 261, 28 L. R. A. (N. S.), 298, 120 Am. St. Rep., 581, 8 Ann. Cas., 1047, there was in-, volved a contract, entered into in 1892, by which the city of Minneapolis, in consideration of the railroad company constructing certain bridges and approaches at the intersection of stipulated streets, expressly agreed that the city would thereafter construct and maintain all crossings or approaches made necessary by the opening of new streets. It was contended by the railroad company that this constituted a valid contract with the city, and, having been complied with on the part of the company, that it was beyond the power of the city later to require the company to construct the bridge over a new street, in question; that to so require' would be to impair the obligation of the contract. The court said:
“In this we do not concur. The power of the State to require the defendants to construct the bridge in question, or any other bridge at streets crossing the right of way is an exercise of the police power, which can be neither contracted away nor lost by inaction on the part of the public authorities. The contract was *406beyond the authority of the city council, and ultra vires, and void” — citing Chicago, etc., R. Co. v. Nebraska, supra.
This Minnesota case was, by writ of error, taken to the supreme court of the United States, where it was affirmed (214 U. S., 497, 29 Sup. Ct., 698, 53 L. Ed., 1060), on the authority of the case of Northern Pacific R. Co. v. Minnesota, ex rel., Duluth, 208 U. S., 583, 28 Sup. Ct., 341, 52 L. Ed., 630.
This last-named case was a companion case to the Minneapolis case, and in it the opinion of the Minnesota court in the Minneapolis case was freely and approvingly quoted by the supreme court of the United States. Referring to rulings of the supreme court of Minnesota to the effect that it lay in the power of the city, at common law, at the time the contract was made with the company, to have required the latter to maintain in safety its crossings with both existing and future streets, and that any contract which undertook to limit the exercise of this right was without consideration, against public policy, and void, the court said, through Mr. Justice Day:
“This doctrine is entirely consistent with the principles decided by this court. But it is alleged that at the time this contract was made with the railroad company it was at least doubtful as to what the rights of the parties were, and that the contract was a legitimate compromise between the parties, which ought to be carried out. But the exercise of the police power cannot be limited by contract for reasons of public policy, nor *407can it be destroyed by compromise, and it is immaterial upon-what consideration tbe contract rests, it is beyond tbe authority of tbe State or tbe municipality to abrogate this power so necessary to tbe public safety.” Northern Pacific R. Co. v. Minnesota, ex rel., Duluth, supra.
It was there again specifically ruled, that tbe defense here urged of impairment óf tbe obligation of a contract was not maintainable. Tbe court well said that tbe police power is a continuing one, and that a requirement imposed on tbe company under it was “not in violation of tbe constitutional inhibition against tbe impairment of tbe obligation of contracts. ’ ’
• We are unable to distinguish tbe case at bar, in principle, from tbe Minneapolis case; and on its facts it is a counterpart of the Duluth case, where tbe contract was one under which tbe city and company shared tbe construction cost of an overhead bridge, and tbe city agreed that it would thereafter forever maintain and keep in repair tbe approaches thereto, and, for a period of fifteen years, tbe structure proper. Within tbe fifteen years tbe city demanded of tbe company that it repair tbe structure, and tbe litigation and rulings related thereto. 98 Minn., 429, 108 N. W., 269.
A fundamental contention of tbe company in this case is that in 1876 tbe duty of constructing and maintaining tbe old bridge was devolved by law on tbe city, and that tbe city bad not power in law to compel tbe company to erect or maintain tbe bridge then constructed. If it be conceded that at that date there was *408no statutory power in the city to that end, did it exist at the common law? This question is also discussed at length in the eases supra, decided by the supreme courts of Minnesota and the United States, where it was held that, by the great weight of authority, the city could enforce the construction and maintenance of such a structure as an obligation imposed on the company by the common law.
In this State as early as 1859 it was held, in Railroad v. State, 3 Head, 523, 75» Am. Dec., 778, that it was the duty of such a company to- construct a suitable crossing, a bridge if necessary, “under the general principles of the common law.” Our later case of Dyer County v. Railway, 87 Tenn., 712, 11 S. W., 943, is in accord, and further holds that the company’s duty was a continuing one as to repair, and that case was cited by the supreme court of Minnesota in the Minneapolis case in support of its own holding. See, also, Railway v. State, 87 Tenn., 751, 11 S. W., 946.
It is clear that, if that right was then by the city deemed doubtful, and that, under doubt as to where to lay the paramount duty to construct and maintain the bridge, the contract was then entered into, in quasi compromise or truce, á later valid exercise of the police power did not work an impairment that was a violation of the constitutional provision invoked.
If it be conceived that the contract of 1876 was valid to an extent, still the contracting parties were charged with notice of the limitation of power on the part of the city in respect of its binding itself not to exercise in *409after years a police power to onerate the company with the constrneton and maintenance of- a safer and more adequate bridge, demanded hy changed conditions, mainly incident to the growth of the city.
The chancellor was not in error in so ruling; decree’ below affirmed, and the cause remanded for further proceedings in accord.