Castellan Holdings, the Manhattan-based real estate investment firm, agreed to settle a lawsuit against its former vice president and allow the sale of an East Village walk-up building to go through, according to a statement released Sunday.

Castellan had won a temporary restraining order in Manhattan Supreme Court in February, claiming that Paulius Skema negotiated the deal to buy the building at 97 Second Avenue through a firm that he personally controlled — even though he was an executive at Castellan at the time.

Castellan, led by managing principal Paul Salib, agreed to withdraw the suit after the parties reached a settlement. Terms of the agreement were not disclosed, but the parties all ended the negotiations on good terms, according to the statement.

“We appreciate Paulius’s contribution ot the firm and we wish him the best of luck in his future endeavors,” said Salib, in the statement.

Attorney Lynn Okin, who represented the defendant, did not return calls. Adam Leitman Bailey, whose firm represented Castellan, also declined to comment on the deal, citing terms of the settlement.

Skema, who started working for Castellan in 2011 and left the firm last month, negotiated the acquisition of more than 30 buildings in his time there. But Castellan filed suit against him in February, alleging that Skema entered a deal to buy the walk up from a Bayside, N.Y.-based entity called 97 Second Avenue Building Corp.

In an affidavit, Toledano — who began acquiring his own properties about six months ago — said he was the buyer of the building. He also noted that he had brokered about 25 deals with Castellan and had done business with Skema as a broker on three previous transactions, including 649 West 184th Street in Manhattan. He indicated he asked Skema to participate as a 1 percent owner in the 97 Second Avenue deal.

Attorney Joseph Zelmanovitz, representing Toledano, declined to comment. But in the affidavit, Toledano said he himself negotiated the agreement to purchase the building from Douglas Pratt, the co-owner of the property, for $4.95 million. He also stated that he approached Salib to discuss whether Castellan would agree to provide short-term financing for the deal. According to Toledano’s affidavit, Castellan agreed to provide between $2.2 million and $2.5 million, in return for a 3 percent upfront fee and 12 percent interest over two years.