The defendant, William A. Cormier, a member of the plaintiff Horse Pond Fish & Game Club, Inc., appeals a decision of the Superior Court (Murphy, J.) granting the plaintiff’s motion for summary judgment. The result of the decision is to declare void the restraint against alienation contained in a deed conveying a certain parcel of land to the plaintiff. We reverse and remand to the trial court for further proceedings.
The plaintiff, Horse Pond Fish & Game Club, Inc., was organized and incorporated in 1945. In 1954 it obtained title to a parcel of land in Nashua (the Horse Pond property) by deed, free of restrictions. The Horse Pond property consists of the land surrounding Horse Pond adjacent to the United States Fish Hatchery and contains the Horse Pond Fish & Game clubhouse and shooting range. The members conduct the activities of a fish and game club on the property.
On December 9, 1958, the plaintiff deeded the Horse Pond property to two of its members, Caleb N. Bickford and Fred A. Parish, who conveyed it back to the plaintiff the same day, with the following restrictions written in the deed:
“That said parcel of land with the buildings thereon or any part thereof shall not be alienated from the Horse Pond Fish and Game Club, Inc. unless:
1. One hundred (100) percent vote of the Club at a special meeting called by written notice to all members and notifying all said members that the purpose of the meeting is to convey away the property or a part thereof.
2. The Club is officially dissolved.”
*650The only reasonable interpretation of this action is that the members desired to encumber the title to the property by the restrictions against alienation as set forth in the deed. Since the plaintiff acquired the Horse Pond property, the neighborhood surrounding the property has become increasingly residential, with the result that the Horse Pond property is bordered on all sides by residential neighborhoods, except for the fish hatchery bounding the property to the east.
In 1987 the plaintiff registered with the charitable trust division of the attorney general’s office as a charitable corporation. The plaintiff’s articles of agreement, restated in its by-laws, which were revised as of September 29, 1981, recite its objectives.
“The purposes for which this club is organized are to conserve, restore, and manage the game, fish, and other wildlife and its habitat in Horse Pond and its environs; to seek to procure better fishing and hunting for sportsmen; to promote and maintain friendly relations with landowners and sportsmen, to cooperate in obtaining proper respect for and observation of the fish and game laws; and so far as possible to spread knowledge of useful wildlife among the residents of Nashua and vicinity. The Association shall operate without profit, shall be non-political and non-sectarian.”
Pursuant to the Horse Pond property deed restriction, and as a consequence of the increasingly residential character of the area surrounding the property, the plaintiff called a special meeting in July of 1988 to approve a land swap contemplated by a purchase and sale agreement between itself and Byfield Associates, a New Hampshire general partnership. Under the agreement, subject to approval by its membership, the plaintiff would retain its clubhouse and approximately seven contiguous acres of the Horse Pond property, and would swap the balance of the property for a certain parcel of land in Hollis (the Hollis property), plus $150,000 payable in three installments. The Hollis property is bounded by the Nashua River on one side and by property held by Lone Pine Hunters, an association similar to the plaintiff, on the other side. According to the plaintiff, the Hollis property is more suitable for its fishing and hunting purposes than the Horse Pond property.
At the special meeting, the defendant, William Cormier, who lives on land adjacent to the Horse Pond property and who is a member of the plaintiff, voted against the proposed land deal. Under the restriction contained in the deed, assuming it to be lawful, his vote was *651sufficient to block the intended transaction. After the meeting, the plaintiff filed a bill in equity in the superior court, seeking a declaration that the restriction in the deed was void as an unreasonable restraint against alienation. All the plaintiff’s members were served or waived service, and only defendant Cormier filed an appearance and an answer.
On April 10, 1989, two months after the bill’s return date, the plaintiff moved for summary judgment. In its motion, the plaintiff requested the court either to declare the deed restrictions void as an unreasonable restraint against alienation or to reform the deed under the doctrine, stated in Asylum v. Lefebre, 69 N.H. 238, 241-42, 45 A. 1087, 1088-89 (1898), that a court sitting in equity may order a conveyance of land held in charitable trust upon petition of the charity’s trustees, if it clearly appears that such action would be beneficial to, and would further the purposes of, the charity. The plaintiff also asserted in its motion that the defendant was equitably estopped from opposing the land swap as a result of a conflict of interest arising from his ownership of land adjacent to the Horse Pond property.
In his objection to the plaintiff’s motion for summary judgment, filed on May 8,1989, apparently in response to the plaintiff’s implication that it held the land in charitable trust, the defendant asserted that “[i]nsofar as the Club may be deemed to be a charitable organization, the rules against perpetuities and restraints upon alienation are inapplicable,” citing Smart v. Durham, 77 N.H. 56, 86 A. 821 (1913). The defendant also contested the plaintiff’s conflict of interest allegation and requested the court to refrain from reforming the deed.
Up until this point, the plaintiff had neglected to inform the director of charitable trusts of the attorney general’s office of the events taking place with regard to the property, including this lawsuit, as contemplated by RSA 7:28,1, although it apparently considered the law governing charitable trusts to be applicable to it, and although it apparently saw itself as holding the Horse Pond property in trust. On July 12, 1989, however, the defendant filed a motion to join the director of charitable trusts as a necessary party to the proceeding. On July 17, 1989, the defendant also filed a motion to continue the trial, which was scheduled to begin July 30,1989, in light of the outstanding motion to join a necessary party. The plaintiff apparently changed its mind in regard to its earlier determination that it held the Horse Pond property in trust, for it alleged in its objection to the motion for joinder, filed on July 18,1989, that it was not a charitable *652trust within the meaning of RSA 7:21, II, but rather was a voluntary corporation under RSA chapter 292, and that it had not registered as a charitable trust because it was not required to do so. The defendant replied on July 21,1989, with a copy of the plaintiff’s registration form filed with the charitable trust division of the office of the attorney general.
On July 17, 1989, however, before the plaintiff had filed its objection to the joinder motion and before the defendant had filed a copy of the registration form or the court had ruled on his motion for a continuance, the court granted the plaintiff’s motion for summary judgment. Applying the rule of reasonable restraints, namely, that the validity of a restraint against alienation depends upon its reasonableness in regard to the justifiable interests of the parties, the court found the restraint in the deed invalid. Using the factors listed in Restatement of Property § 406, comment i (1944), to determine reasonableness, the court held unreasonable the restriction requiring a one hundred percent vote of the plaintiff’s members, because it was unlimited in duration, and found the restriction requiring the plaintiff to be dissolved before the Horse Pond property could be alienated to be unreasonable, in that it was “capricious and its enforcement would accomplish no worthwhile purpose.”
Shortly thereafter, on July 25,1989, the defendant filed a motion to set aside the order granting summary judgment, alleging that the court had erred in finding no genuine issue of material fact when the issue of the plaintiff’s charitable status had not been resolved. The defendant also asserted that the court erred in its application of the law, because the deed restriction ensured that the Horse Pond property would be used for the plaintiff’s purposes and was, consequently, lawful. The plaintiff filed an objection to the motion to set aside and, to correct its earlier mistake regarding its registration with the charitable trusts division, filed a tardy supplemental objection to the motion to join the director of charitable trusts. In that objection, the plaintiff admitted that it had registered with the charitable trust division and acknowledged that the director was a “technically] necessary” party. It claimed that, according to the director of charitable trusts, the division would review the propriety of intervention in light of the court’s order, and would intervene if it judged it necessary to protect the State’s interest. The trial court never ruled on the motion for joinder or the motion to continue the trial, and on August 15,1989, denied the motion to set aside its order “as it *653raise[d] no issues not previously ruled upon by the court.” This appeal followed.
The defendant argues that the trial court erred in granting summary judgment when the plaintiff’s status as a charity was in issue and when there was a motion pending before the court to join the director of charitable trusts as a necessary party. He also asserts that the restrictions in the deed to the plaintiff are valid in view of the plaintiff’s charitable status. We do not reach the defendant’s last argument because we hold that the trial court erred in granting summary judgment at a time when the plaintiff’s status as a charitable entity was unresolved.
The court shall grant a motion for summary judgment pursuant to RSA 491:8-a if, after considering all the evidence in the light most favorable to the non-moving party, it finds that there is no genuine issue of material fact and the moving party is entitled to judgment as a matter of law. Heaton v. Boulders Properties, Inc., 132 N.H. 330, 335, 566 A.2d 1127, 1130 (1989). An issue of fact is “material” if it “‘affects the outcome of the litigation. . . .’” DesRoches v. United States Postal Service, 631 F. Supp. 1375, 1379 (D.N.H. 1986) (citations omitted). For the reasons that follow, we find that the issue of whether the plaintiff is a charitable entity is material to the determination of the validity of the restrictions contained in the plaintiff’s deed to the Horse Pond property.
“Much of modern property law operates on the assumption that freedom to alienate property interests which one may own is essential to the welfare of society.” Restatement (Second) of Property, Donative Transfers, introductory note, at 143 (1983). Because all restraints against alienation are contrary to this policy of freedom of alienation, to be enforceable they must be reasonable in view of the justifiable interests of the parties. See id. § 4.1, comment a at 159; 61 Am. Jur. 2d Perpetuities and Restraints on Alienation § 102 (1981). Correspondingly, unreasonable restraints will be held invalid. 61 Am. JUR. 2d supra.
The rule of “reasonable restraints,” however, generally does not apply in the case of a gift to a charitable trust or charitable corporation. Annotation, Validity and Effect of Provision or Condition Against Alienation in Gift for Charitable Trust or to Charitable Corporation, 100 A.L.R.2d 1208, 1209 (1965) (hereinafter Annotation). In other words, an express provision or condition against alienation contained in a gift made to a charitable trust or *654charitable corporation may constitute a valid restraint. Id. This result is consistent with Restatement of Property § 406, comment i at 2406-07 (1944), which states that one of the factors tending to show the reasonableness of the restraint is that “the one upon whom the restraint is imposed is a charity.”
“The reasoning on which this result is arrived at would seem to be that since a donor may make a gift for charitable purposes perpetual in duration [i.e., the rule against perpetuities does not apply to gifts for charitable purposes, see Restatement (Second) of Trusts § 365, comment a at 245 (1959)], he may, as a corollary of this right, and in order to effectuate his primary purpose, impose a condition that the gift property shall not be alienated . . . .”
Annotation supra; see also Asylum v. Lefebre, 69 N.H. at 241, 45 A. at 1088 (stating that a general or partial restraint against alienation is not invalid in the case of a gift to a charitable trust). Yet a sale of land owned by a charitable entity may be permitted, despite a valid restraint against alienation, if a court of equity determines that, due to unforeseen circumstances, the sale is necessary and would be in the best interests of the charity. Asylum v. Lefebre, 69 N.H. at 241-42, 45 A. at 1088-89.
Since the restraint against alienation contained in the plaintiff’s deed to the Horse Pond property may be valid, depending upon whether or not the plaintiff is a charitable entity, the issue as to the plaintiff’s charitable status, which existed at the time the court ruled on the plaintiff’s motion for summary judgment, is a material issue which precluded the court from granting a valid summary judgment in the present case. Accordingly, we reverse the court’s decision and remand for further proceedings in accordance with this opinion. On remand, the court should determine whether the plaintiff is a charitable entity and, if so, whether the restraint against alienation contained in the deed is valid, or whether the plaintiff is a non-charitable entity, in which case the rule of reasonable restraints must be considered and the court’s earlier determination that the restraint is unreasonable will stand. In the event the court decides that the plaintiff is a charitable entity, the director of charitable trusts shall be joined as a party to this action. See Concord Nat. Bank v. Haverhill, 101 N.H. 416, 419, 145 A.2d 61, 63-64 (1958) (noting that the attorney general, or the director of charitable trusts as his representative, is an indispensable party in any judicial proceeding involving the enforcement and supervision of charitable trusts) *655and Restatement (Second) of Trusts § 348, comment / at 212 (1959) (stating that a charitable corporation is under a duty, enforceable at the suit of the attorney general, not to direct property it has been given to purposes other than the charitable purposes for which it was organized).
Reversed and remanded.
HORTON, J., did not sit; the others concurred.