delivered the opinion of the Court.
This was a suit instituted in the name of the plaintiff, to the use of Richard Mason’s administrators, against the defendant, as security to an administrator’s bond, in the Circuit Court, where two motions were made; one hy the counsel for the defendant to dismiss the suit, for the want of bond and security for the costs; the other *455by the counsel for the plaintiff, to he permitted to file hond and security for costs. The first motion was sustained, and the suit dismissed; the other was consequently overruled. The question for the consideration of this Court is, whether the Circuit Court erred in refusing to permit the security to he given, and in dismissing the suit for want thereof? The first section of “ an act concerning costs,” passed the 26th of January, 1825, Rev. Code, p. 225, provides, “ that in all actions on ofiice bonds for the use of any person, actions on the bonds of executors, administrators, or guardians, qni tarn actions, actions on any penal statute, and in all cases in law or equity, where the plaintiff or person for whose use the action is to he commenced, shall not be a resident of this State, the plaintiff or person for whose use the action is to be commenced, shall, before he institutes such suit, file or cause to be filed with the Clerk of the Circuit Court in which the action is to he commenced, the bond or obligation of some •person being a resident of this State, whereby h,e shall acknowledge himself bound to pay, or cause to he paid, all costs which may accrue in such action; and if such action shall be commenced without filing such bond or obligation, the Court, on motion, shall dismiss the same,” &c. The twenty-second section of the same act subjects the equitable plaintiff, or person to whose use an action is brought, to the payment of costs, &c. Ths only object which these pro-visions of the statute seem intended to secure is, that the officers of'the Court shall be paid their legal demands for fees and services, and to that end it is provided, that the oqitable as well as legal plaintiff) when non-resident, shall file, or cause to be filed, “the bond or obligation of some person being a resident of this State.” It is not to he supposed, that the policy of the statute is to restrain or discourage the bringing of suits. Its provisions, therefore, which arc merely directory, should receive the construction best calculated to promote the views of the Legislature in securing to the officers of the Court their legal fees. That object will be as effectually attained, by giving proper security after, as before the institution of suit, and will certainly ho furthered thereby. It was surely never intended that the Court should he deprived of all discretion whatever; thus, though “ the hond or obligation of any person being a resident of the State,” might satisfy the terms of the act, it would not be contended that the bond of any insolvent resident would be a compliance with its provisions. Nothing is more usual than for Courts, in construing statutes, to substitute indifferently the words “may” and “shall” for each other, where the plain and obvious end to be attained by the statute, requires an extension or restraint of the discretion of tho Court. In the cause under consideration, and in all such cases, it is believed, that the object of the Legislature would he advanced, by taking from the plaintiff such hond and security for the costs incurred and to he incurred, as the Court, in its sound discretion, may find and adjudge to he good and sufficient.
Let the judgment of the Circuit Court he, therefore, reversed, and the cause remanded for further proceedings therein, conformably to this opinion.