delivered the opinion of the court.
The plaintiff, Louise E. Bowles, proceeded by motion for damages in the circuit court for the city of Richmond against the city of Richmond and the Richmond, Fredericksburg and Potomac Railroad Company for injuries received by her by reason of the negligent failure of the defendants to properly safeguard the approach on Broad street to the old bridge over the belt line of the railroad company, where the approach had been cut down and abandoned temporarily for a detour to a new bridge at grade with the street. The city of Richmond filed a special plea which averred that the plaintiff had . not within six months after the cause of action accrued filed with the city attorney a written statement of the particulars of the accident, verified by the oath of the plaintiff or her agent or attorney, as required by the city charter.
*724The plaintiff objected to the filing of the city’s plea and moved to strike it ont, because the provision in the city charter was unconstitutional, which objection and motion the court overruled and the plaintiff excepted.
The defendant railroad company did not plead to the plaintiff’s motion, whereupon the plaintiff filed her replication to the defendant city’s plea.
The city demurred to her replication in which she joined, and upon argument the court sustained its demurrer and ordered that the action of the plaintiff be dismissed as to the defendant, the city of Richmond. Nothing was done in the case against the railroad company. The plaintiff sued out a writ of error to this ruling of the court, and the case is here for review on these two points.
Counsel for the city in its reply brief makes the point that- the writ of error should be dismissed as improvidently awarded for the reason that no action of any kind has been taken in reference to its codefendant, the railroad company, therefore the judgment upon the demurrer was not final, and the writ of error should be dismissed. He cites as authority for this position Wells v. Jackson, 3 Munf. (17 Va.) 458.
Section 19-g of the charter of the city of Richmond, Acts of Assembly 1918, p. 182, makes it compulsory in every action to recover damages for any negligence in the construction or maintenance of any of its streets, alleys or parks, where any person is liable with the city, that every such person shall be joined in such action against-the city, and where there is a verdict or judgment against the city as well as the other defendant, it shall be ascertained either by the court or jury which of the defendants is primarily liable for the damages assessed. This charter provision makes a change in common law rules of procedure as far as suits for negligent injuries against the city are concerned.
*725At common law, in ease of joint wrongs, the plaintiff may at,his election sue all or any one, or any intermediate number of the wrongdoers, but in order to sue all there must be a joint wrong. In an action against several doers for a joint wrong, there can be only one final judgment upon the merits. There may be different writs of inquiry executed against different defendants, or the jury may find for different amounts against the defendants, but the plaintiff still retains his election to stay execution and proceed to judgment-against all, then elect to accept the highest judgment, or he may dismiss the proceeding as to those defendants against whom judgment has not been taken. Until he has dismissed the case as to the joint wrongdoers against whom he has no judgment, or signifies an intention to prosecute the action to judgment against them, as all are jointly liable, there is no final judgment, therefore, there could be no appeal. Wells v. Jackson, supra, Ammonett v. Harris & Turpin, 1 Hen. & M. (11 Va.) 488. The principle of law above mentioned does not apply to the instant case, as there is no joint interest between the defendants in the matters decided by the circuit court, not does it relate to the merits of the case, therefore the judgment is final as to the city and the writ of error properly here.
The provision of the city charter, section 19-g, Acts 1918, p. 182, which was the basis of the city’s plea, is as follows:
“No action shall be maintained against the said city for damages for an injury to any person or property alleged to have been sustained by reason of the negligence of the city, or of any officer, agent or employee thereof, unless a written statement, verified by the oath of the claimant, his agent or attorney, of the nature of the claim and of the time and place at which the injury *726is alleged to have occurred or been received shall have been filed with the city attorney of said city within six months after such cause shall have accrued.”
The plaintiff contends this provision of the charter is unconstitutional because it gives special privileges to the city that are not given to its codefendant.
Consideration of the nature and functions of municipal corporations; that they are created by law; that all their powers are derived from the statute creating them; that their purposes are local self government and general welfare of particular communities; that the care and maintenance of their streets are delegated powers from the State, performed for the benefit of all people; that all of their liabilities are imposed by the statute, and that it is within the power of the General Assembly to give them immunity from suits for negligence, will demonstrate that no constitutional question is involved in this case. Constitutions are to protect citizens in their reserved rights, and not to grant immunity from wrong. O’Neil v. City of Richmond, 141 Va. 168, 126 S. E. 56. The General Assembly in the exercise of its plenary power, having required notice in writing before suit against the city for negligence is brought, the court was right in overruling the plaintiff’s motion to strike out the city’s plea.
The issue presented and decided upon the city’s demurrer to the plaintiff’s replication does not involve the principle of the statute of limitations, that is, the principle of repose; but whether the charter provision in reference-to verification of the notice of the injury to the city attorney is mandatory. Similar provisions to the one under consideration in this case are found in the statute law of other States of the United States, and have been before the courts for con*727struction. These statues have been suggested by experience and the reason for them has been frequently indicated in the opinions of the courts. “They afford the city authorities the opportunity to investigate the circumstances, examine the locality in which the injury is alleged to have occurred, and to discover the witnesses promptly so as to ascertain the facts while their recollections are fresh. Such statutes tend to discourage and avoid the expense of litigation, because, if the investigation discloses legal liability a prompt settlement is both proper and probable. They also tend to prevent perjury and fraud as well as to avoid injustice growing out of the failure of the witnesses to recollect clearly occurrences long past, before they are called upon to testify, and thus better to safeguard against unfounded claims.” O’Neil v. City of Richmond, 141 Va. 168, 126 S. E. 56, 57.
While the courts are unanimous that giving the notice is a condition precedent to the right to bring the suit, still recognizing that the reason of the law is the life of the law, they hold that the statute should have a liberal construction, and a substantial compliance with it is sufficient. The city by its demurrer admits that the city attorney had complete and actual notice of the accident; that he thoroughly investigated its causes and the city’s liability, and in writing denied all responsibility for her injuries. Thus every purpose of the requirement of notice of the charter was met, and the city’s law office put in possession of every fact and circumstance essential to a just determination of the plaintiff’s claim.
The contention of the city, however, is that the failure to verify the notice makes the notice void and equivalent to no notice. Affidavits to notices and proceedings are frequently required by the statute law, *728and practice of the courts, so that whether the requirements of affidavits in such cases are directory or mandatory has been settled by adjudication. The rule of reason and principle applicable in the construction of such provisions of law is very clearly enunciated by Judge Cooley in Cooley’s Const. Lim., and quoted with approval by the Supreme Court of Appeals in the case of Jackson v. Dotson, 110 Va. 46, 65 S. E. 484 (which was a case involving the sufficiency of an affidavit to a plea required by statute), as follows: “Those directions which are not of the essence of the thing to be done, but which are given with a view merely to the proper, orderly and prompt conduct of the business and by a failure to obey which the rights of those interested will not be prejudiced, are not commonly to be regarded as mandatory, and if the act is performed but not in the time nor in the precise mode indicated, it will be sufficient if that which is done accomplishes the substantial purpose of the statute.’’
The notice with affidavit as provided in the city’s charter was for the information of the city attorney, and he was not required to act until proper notice was served upon him, but if he acted upon a notice without affidavit, and every substantial purpose thereof has been accomplished, and he denied in writing all liability of the city, it is in the highest degree technical to hold the affidavit to the notice a condition precedent (when he did not so regard it) to the right of the plaintiff to bring her suit, and does not present the case to the court for trial according to the very right.
The demurrer of the defendant city should have been overruled, and this court will set aside the judgment of the circuit court of the city of Richmond and remand the case for further proceedings.