A federal bankruptcy judge Friday approved a bid from the parent company of ShopRite to buy the lease of a former Waldbaum’s in Massapequa for $300,000.

During a court hearing in White Plains, the judge approved the bid made last month by Wakefern Food Corp., a cooperative operating under the ShopRite banner on Long Island, to take over the vacant Waldbaum’s location at 5508 Sunrise Hwy. in Massapequa from former supermarket operator Great Atlantic & Pacific Tea Co.

advertisement | advertise on newsday

Wakefern will sublease to Buonadonna ShopRite LLC, based in Bay Shore, according to court documents filed last month with the U.S. Bankruptcy Court in White Plains.

In October, a bankruptcy court judge approved bids from Wakefern to buy the leases of a Waldbaum’s store in Deer Park and two Pathmark stores, in Bethpage and New Hyde Park, as part of a $40 million purchase package of 12 former A&P stores. Those three ShopRite stores are expected to open in the spring after undergoing renovations, a company spokeswoman has said.

All 51 Waldbaum’s and Pathmark stores operated by A&P on Long Island closed by November. All of the stores have now been accounted for, after 30 were purchased by supermarket chains, 20 were turned over to their landlords, and one was sold to a real estate company.