Simmons, C. J.
Mrs. McCardle brought an action for divorce against her husband, C. L. McCardle, and a divorce was granted her. In the decree the judge awarded her the custody of the children. She subsequently married Haire. The decree in the divorce proceedings allowed the father to visit the children, but the mother preferred instead to send the children to visit the father. On one occasion when two of them, under the age of twelve, were so sent to visit the father, the latter refused to return them; whereupon the mother sued out a writ of habeas corpus to obtain possession of the children thus detained. On the trial before the ordinary the father sought to amend his answer to the writ, by alleging that the minor children sued for were being reared by the mother under immoral, obscene, and indecent influences, likely to degrade their moral characters and devote them to vicious lives. The ordinary refused to allow this amendment, and awarded the children to the mother. McCardle sued out a writ of certiorari from the superior court, and on the hearing in that court the judge thereof overruled the decision of the ordinary and held that he erred in refusing to allow the amendment ,to the answer. He directed that the defendant in certiorari pay the costs of taking the case to the superior court and all the costs that accrued in that court. To this ruling and judgment the defendant in certiorari excepted.
1. The judge of the superior court was clearly right in .reversing the judgment of the ordinary and in allowing the amendment offered by McCardle in the trial of the habeas cor*777pus case. Section 2505 of the Civil Code provides that “Whenever any child under the age of twelve shall be brought before the ordinary of the county of such child’s residence, upon "the sworn allegation of any citizen, . . that such child is being reared up under immoral, obscene, or indecent influences, likely to degrade its moral character and devote it to a vicious life, and it shall appear to such ordinary by competent evidence, including such examination of the child as may be practicable, that by reason of the neglect, habitual drunkenness, lewd or other vicious habits of the parents or guardians ■of such child, it is necessary to the protection of such child . . from degradation that such parents or guardians shall be deprived of the custody of such child, such ordinary may commit .such child to any orphan asylum or other charitable institution ■established according to law in this State which is willing to receive such child, or appoint a proper guardian therefor, or make such other disposition of them as now is, or may hereafter be, provided by law in cases of disorderly, pauper, or destitute children.” Under this section any citizen, if he knows that young children are being reared under these improper influences, may make a sworn statement of the facts, and the •ordinary is authorized to take the children away from their parents or guardians and make such disposition of them, under the law, as he may think proper. Had these children been in the custody of their mother, the father or any other citizen ■could have made these allegations, and upon proper proof the ordinary could have deprived the mother of their custody. 'The fact that she sued out the writ of habeas corpus and that the father was the defendant therein did not, in our opinion, prevent his amending his answer so as to make these allegations. Any citizen in whose custody the children had been ■could haye defended such a suit of habeas corpus by making this kind of return in answer to the writ. The right to make this defense could be exercised by McCardle, not by reason of his being the father of the children, for the court had deprived him of all parental custody and control of them, but by reason ■of his being a citizen of the State and county. The code gives ■this right to any citizen, for the purpose of protecting young *778children, in their health and morals, and we see no reason why the father could not, as a citizen, make this defense as well as-any other citizen; nor do we see why it could not be set up by way of defense, by a citizen who had custody of the children,, in answer to a writ of habeas corpus.
2. The court, in sustaining the certiorari and ordering a new trial, gave judgment in favor of the plaintiff therein for the-costs of taking the case to the superior court and for the costs-in that court. Section 4655 of the Civil Code allows this only when the judge of the superior court makes a final disposition of the case. “ If the certiorari shall be returned to the court-below for a new hearing, the plaintiff shall sign up judgment, for the costs in said superior court only, leaving the costs paid to obtain the certiorari to abide the final trial below.” Under this provision.of the code, the court erred in its judgment as-to costs; and it is directed that so much of the judgment as requires the defendant to pay the costs of taking the case to the-superior court be stricken and the judgment then stand affirmed..
Judgment affirmed, with direction.
All the Justices concurring..