The complaint was demurred to upon two grounds: First, that there is a defect of parties plaintiff; and, second, that the .complaint does not state facts sufficient to constitute a cause of action. The *192action was brought upon an undertaking given upon an appeal to the Court of Appeals from an order of the General Term of the Supreme Court dismissing a writ of certiorari. The complaint alleges that one Higgins made an application for a writ of certiorari to review the proceedings of the mayor, corporation counsel and the commissioner of public works' of the city of New York removing him from the position of clerk of the Oity Record / that such writ was dismissed by the General Term of the Supreme Court, and that Higgins appealed to the Court of Appeals; that 'on such appeal the defendants executed an undertaking, by which they jointly and severally undertook that Higgins would pay all costs and damages which might be awarded against him if said order should be affirmed or the appeal dismissed, together with all costs and damage which might be awarded against the appellant, not exceeding $500; that subsequently, the said order of the General Term so appealed from was affirmed by the Court of Appeals, with costs, and that the costs of the said proceedings in the Court of Appeals were duly taxed and adjusted at $104.07; that “at all the times hereinafter mentioned, Hugh. J. Grant was mayor of the city of New York, William H. Clark was counsel to the corporation of said city, and Thomas E. Gilroy was the commissioner of Public Works of said city, and that all of said persons were paid a salary for their services from the city treasury. Section 56 of the Consolidation Act (Chap. 410 of the laws of 1882) provides that “ No officer or person who is paid a salary for his services from the city treasury, and who entered upon his office since May 28, 1880, or shall hereafter enter upon his office, shall receive to or for his own use any fees, costs * * * or moneys paid to him in his official capacity; but all fees, costs * ' * * and moneys so paid or received by any officer or person shall be the property of the city, and shall be paid by 'him into the city treasury;” and that by virtue of this statute the title to the costs awarded to Hugh J. Grant, mayor of the city of New York, William II. Clark, counsel to the corporation, and Thomas F. Gilroy, commissioner of public works, in the certiorari proceeding before referred to, became vested in and became the property of these plaintiffs. The undertaking of the defendants was that they jointly and severally undertook that the appellant would pay the costs and damages which might be *193awarded against Mm if said order should be affirmed. These costs were awarded against the appellant in the certiorari proceeding, and the defendants became bound to pay them. By virtue of the statute, the costs awarded in favor of these public officers whose proceedings were sought to be reviewed by the writ of certiorari became the property of the city, and thus, by virtue of the statute, the city became entitled to such costs and was the proper plaintiff in an action to enforce any obligation to pay such costs. As section 449 of the Code of Civil Procedure provides that the action must be brought in the name of the real party in interest, and as the plaintiff was the owner of the costs and entitled to receive them, the plaintiff was the real party in interest and entitled to bring an action to enforce an obligation to pay them. (Sutherland v. Carr, 85 N. Y. 105 ; Board of Education of Auburn v. Quick, 99 id. 138.)
The respondents in the cértiorari proceedings were not necessary parties to this action, as the costs became, by the act before referred to, the property of the'plaintiff, , and such respondents had no personal interest therein.
The judgment appealed from is, therefore, affirmed, with costs.
Van Brunt, P. J., Patterson and McLaughlin, JJ., concurred.
Judgment affirmed, with costs.