After a long legal fight, Weil, Gotshal & Manges has finally put to rest a dispute over whether a community of Orthodox Jews can erect a nearly invisible religious boundary that allows them to perform certain work tasks forbidden on the Sabbath.

The five-year legal battle between three municipalities in the Hamptons, a region of wealthy beachfront communities that populate Long Island’s East End, came to an end Thursday evening when the village of Westhampton Beach, New York, agreed to settle with the Orthodox group, ensuring that their marked-off area, known as an eruv, would remain intact.