Stephen, J.
delivered the opinion of this court.
The question involved in this case being one of some novelty in point of principle, and the amount of the property de*25pending upon the decision of it being of considerable value, and therefore materially affecting the interests of the parties litigant, it has received, as it demanded, the careful and deliberate consideration of this court. The case has been ably and ingeniously argued by the counsel engaged for the respective parties, and much aid has been derived during our researches, from the light thrown upon it by the discussion at the bar. Upon the fullest examination we have been able to bestow upon it, we have come to the conclusion that there is no error in the decision of the court below, and that the judgment there rendered ought to be affirmed. In deciding upon the merits of this controversy, we think that the true construction of the will of the testator in reference to the character of the legacy given to his grand-daughter, Mrs. Stevenson, that is, whether it was absolute, or for her separate use, is wholly immaterial and irrelevant, and that the rights of the parties must depend upon the validity or invalidity of the agreement, under or in virtue of which it was paid over to her husband* Under this aspect of the case, many of the prayers made by the appellants’ counsel in the court below, which kept out of view the operation and effect of that agreement, were wholly abstract, and did not involve the true point in controversy between the parties, and therefore received at the hands of the court that fate, which upon established legal principles, unavoidably awaited them, it being the undoubted duty of the court not to wander or suffer themselves to be led into the wide and extended fields oflegal science, for the purpose of solving or settling legal principles having no relevancy to the case before them, but to eonfine themselves to those questions of law alone, which arise upon the facts and circumstances established by the testimony, and which properly belong to the case before them. The great and leading question therefore in this case seerns to be, whether the agreement made by the husband of Mrs. Stevenson with the executors of her grand-father’s will* if satisfactorily proved to have existed, was founded upon a sufficient consideration to render it obligatory upon him, so as upon the non-fulfilment of it on his part* to create the relation *26of debtor and creditor between him and his wife. We cannot entertain a doubt of the sufficiency of the consideration to support his promise to the executors, in reliance upon which they paid him the legacy. If it was founded upon an equitable duty, such as would be enforced by a court of equity, that alone seems to be sufficient to give it efficacy, and binding operation, even in a court of law. In Cowper’s Rep. 290,, Lord Mansfield says, “where a man is under a moral obligation which no court of law or equity can enforce, and promises? the honesty and rectitude of the thing is a consideration. As if a man promises to pay a just debt, the recovery of which is barred by the statute of limitations; or if a man, after he comes of age, promises to pay a meritorious debt, contracted during his minority, but not for necessaries; or if a bankrupt in affluent circumstances, after his certificate, promises to pay the whole of his debts; or if a man promise to perform a secret trust, or a trust void for want of writing by the statute of frauds. In such and many other instances, though the promise gives a compulsory remedy, where there was none before either in law or equity, yet as the promise is only to do what an honest man ought to do, the ties of conscience upon an upright man are a sufficient consideration;” and Butter, Justice, in his opinion says, “the true rule is, that wherever a defendant is liable in equity and conscience to pay, that is a sufficient consideration;” and he says that the rule, that to constitute a valid consideration for a promise, there must be a benefit to the promisor or loss to the promisee, is much too narrow. The executors in this case held the wife’s legacy as trustees, and wherever it is necessary for a husband to resort to a court of equity to get possession of his wife’s legacy, that court will require him to do equity, by making a settlement upon his wife and children,, before it will lend him its aid in the recovery of it. This is considered to be an equitable duty on his part, and formed, we think, a sufficient consideration for his promise in this case. The waiver moreover on the part of the executors of the refunding bond, which it appears by the laws of Pennsylvania they had a right to require, formed' an additional consideration *27for the agreement on the part of the husband for the benefit of his wife. It is also to be considered in the decision of this controversy, that according to the proof, the husband received the money of his wife, not in virtue of his marital rights, so as to amount to a reduction of the legacy into possession, but as her trustee and for her benefit; on the death of the husband therefore, it continued to be her property, for which she had a claim against his estate, and did not go to his personal representatives. On this point the authorities hold a language uniform, explicit and unequivocal.
The agreement then being valid and obligatory upon the husband, is to be considered as a substitution for the equity of the wife, which operated for the benefit of the wife and children, though not named, and which a court of equity would specifically execute against the husband, upon a bill filed for that purpose. In support of this doctrine, see the case of the Attorney General vs. Whorwood, where Lord Hardwick recognises the validity of an agreement made by a husband with a trustee, for the purpose of obtaining his wife’s money out of his hands, which the trustee had received upon the sale of her father’s estate, and decreed an execution of the agreement, on the death of the husband, against his representatives. The agreement was, to invest the money in the purchase of land, to be settled for her benefit for life, and if there were no children, then on himself. In that case his lordship said “that it had been truly insisted, on behalf of the wife, that on the husband’s application for the money, the court would undoubtedly have ordered a further settlement.” If then the parties did not come into court, but acted among themselves, and the husband had agreed to do that which the court would have directed, had the wife insisted on it in a proper suit, it should have its full effect. It has been solemnly settled by this court, and has also been decided by Chancellor Kent, in New York, that the wife’s equity will prevail against an assignment of the husband for valuable consideration or in payment of a just debt. See 4 G. & J. 282; 5 John. C. Rep. 484, where Chancellor Kent also decides, that the court may, in its discretion, *28give the whole or part only of the property to the wife according to the circumstances of the case; to same effect, see 6 John. C. Rep. 178.
If we are correct in the views which we have taken, as to the binding and operative effect of the agreement of the husband in this case, the next question which arises is, did his failure to invest according to the terms and conditions under which he received the legacy, give to his wife the right to elect to consider him her debtor to the amount of it, as so much money bad and received to her qse? Upon principle, and authority, we think it did give her that right. He received the money upon a special trust and confidence, th^J it would be invested for her benefit; he received it as her trustee; and upon his failure to make that investment, the consideration upon which he received it failed, and she had a right to consider it as so much money had and received for her use. See 1 Harr. & Gill, 258, where it is said, “if one man takes another’s money to do a thing, and refuses to do it, it is a fraud; and it is at the election of the party injured, either to affirm the agreement, by bringing an action for the non-performance of it, or to disaffirm the agreement ah initio, by reason of the fraud, and bring an action for money had and received for his use.” The action for money had and received is an equitable action, and equally as remedial in its effects as a bill in equity. In Moses vs. Macfarlan, 2 Burr. 1012, Lord Mansfield says, “the gist of this kind of action is, that the defendant, upon the circumstances of the case, is obliged by the ties of natural justice and equity to refund the money.” There can be no doubt that the wife may be a creditor against her husband’st estate, after his death. 1 Harr. & Gill, 280; Powell on Contracts, 109; 3 P. Will. 335; 1 Vernon, 427. These last cases, it is true, were cases in equity, and there were no creditors to contend with, but they shew that as between husband and wife the relation of debtor and creditor may exist; and in the case in Vernon, the wife was administratrix of her husband, and was permitted to retain for her claim out of his assets. But whether the debt be legal or equitable, this court have decided, *29it is equally within the power and jurisdiction of the orphans court to allow it. In this case, however, for the reasons already given, we think the claim of the wife supported by such considerations as constitutes it a debt recoverable in a court of law. We do not think that the decision of this court, reversing the decision of the orphans court allowing the claim, can operate to bar the recovery, it being the exercise of an appellate jurisdiction, reviewing the order of an inferior court, possessing in reference to the subject before it, a prima facie jurisdiction only. As to the objection, that the executors transcended their powers in demanding the execution of the agreement, before they would consent to pay over the money to the husband, we think that it is entitled to no consideration. The agreement having been entered into by the husband, with a full knowledge of all the facts, without fraud or surprise, and being founded upon a valid consideration, cannot be otherwise than obligatory. It seems, however, that the executors may interfere to protect the wife’s equity; for in 5 John. C. Rep. 473, Chancellor Kent refers to a case where it appears the bill was filed by the executor of the testator, to stay the husband who had instituted a suit in the spiritual court for his wife’s legacy. Lord Mansfield said, it made no difference who was plaintiff in equity, and he directed that the money should be disposed of for the benefit of the wife. We do not think that the husband can shelter himself under a mistake of the law; he not only appears to have taken legal advice upon the subject of his marital rights, in relation to the legacy, but if he had not, there is, we think, nothing in this case to except it out of the operation of the general rule, that ignorance of the law cannot be made available with a full knowledge of all the facts. The case of Bowley and Lammott was decided upon a principle wholly inapplicable to this case. That was a case where a forfeiture of title would have been incurred, if the general rule, that a knowledge of the law in civil cases shall be presumed, where there is a full knowledge of the facts, had been permitted to operate; it was to charge the party with a fraudulent concealment of title, in the absence of actual *30knowledge, upon the legal presumption, which imputed knowledge. In that case, the application of such a principle was looked upon as being too monstrous and unjust, to receive for a moment the countenance or sanction of the court; it was a doctrine most glaringly unjust, and alike repudiated by the rules of morality, a refined sense of justice, and the principles of law. It was therefore rejected. We think there is nothing in the objection, that the claim of the wife against her husband’s estate had not been allowed by the orphans court; the decision of that court, whether favorable or unfavorable, not having a conclusive effect upon the question, when submitted to a court of law for adjudication.
We believe we have now taken a view of all the questions involved in the prayers piade by the respective parties in the court below', and upon the best consideration we have been able to give to the subject, we approve of the judgment of that tribunal, and think it ought to be affirmed.
The first, second, third and fifth prayers made to the court below by the counsel for the plaintiff, were properly rejected, as being mere abstract legal propositions, putting the agreement entirely out of view, upon which the defendant rests her claim to retain.
The fourth, we think, was properly rejected for the reasons before expressed.
The sixth prayer, as to the binding effect of the decision of the Court of Appeals, in the case of the appeal from the orphans court, W'as properly rejected for the reasons already given. The effect of the agreement, as now proved, not being in the view of that court when the decision was made.
The seventh prayer was, we think, also properly rejected; for the reasons already given, we think the agreement was a valid one, and supported by an adequate consideration.
The eighth prayer, founded on a mistake of law, for the reasons already assigned, was likewise properly rejected.
The ninth prayer was also properly rejected; under the agreement, it was his duty to invest; no laches is imputable to the wife or executor, so as to create a forfeiture: if a delu*31sion existed, it sprung from his bad faith, he having always declared his intention to be, to make the investment according to contract.
The tenth prayer was also properly rejected, for the reasons already given. The proposition contained in this prayer was too untenable to receive for a moment the sanction of the court, that is, that the claim of the wife was totally destitute of evidence to support it.
The court, we think, were right in rejecting the eleventh prayer, for the reasons already given; the claim, we think, did not require the sanction of the orphans court.
The court, we think, were right in rejecting the twelfth prayer, there being no evidence in the case to sustain it.
The court were clearly right in rejecting the thirteenth prayer; there was evidence sufficient to go to the jury to prove such promise.
The court were right in rejecting the fourteenth prayer, for the reasons before stated.
The court, were right in rejecting the ffteenth prayer, foi reasons which have beer, already stated; there was a sufficient consideration to sustain the promise.
The court were right in rejecting the sixteenth prayer, there being no evidence to warrant it.
Tor reasons already given, the court were right in rejecting the seventeenth prayer; if the agreement was a valid one, her consent when the money was paid under it, would not annul or vacate it. She was entitled to the benefit of it, and her consenting to the payment of the money when it was paid, without at that time annexing any conditions or qualifications to such payment, would not deprive her of the benefit of that agreement. No stipulation on her part was necessary for the protection of her interest. She had a right to rely upon and claim the benefit of the contract which had been made by the executors for her use.
The court were also right in rejecting the eighteenth prayer. The release had nothing to do with the agreement; the agreement having been made, the release was made to *32discharge the executors, it was only collateral to the agreement. The prayer was clearly not warranted by the proof, and was, therefore, properly rejected.
, The nineteenth prayer was properly rejected. Mrs. Stevenson being one of the personal representatives of her husband, could institute no suit against herself, at law; the act of limitations, therefore, did not apply to the case, and created no bar to the recovery of her claim.
The court were right in granting the defendant’s prayer; the record containing sufficient evidence to warrant the jury in finding the facts upon which it was predicated. The judgment of the court below is affirmed.
JUDGMENT AFFIRMED.