On June 23, 2016, the UK voted to leave the EU. The very next day Jolyon Maugham, a British lawyer, set out to find legal ways to stop Brexit. After more than two years of trying, he might finally succeed.

It’s easy to get bogged down by the sheer amount of news on the Brexit front. Banks are moving, carmakers are struggling, the pound is falling, and the British prime minister doesn’t have a plan that her own party backs. But to understand how to stop Brexit, we need to go back to the beginning.

Nine months after the June 2016 vote, Theresa May, the new British prime minister, finally triggered Article 50 of the Lisbon Treaty that binds the EU’s 28 member nations together. The Article gives the UK two years to negotiate the terms of its separation, including divorce payments, rights of citizens from the UK and the EU, and perhaps even a trade deal.

The two-year deadline is on March 29, 2019, and it’s unclear what the state of negotiations will be by then. If the UK fails to negotiate a deal, it will crash out of the EU. The British government’s advice says that, in case there isn’t a deal, the country should stockpile medicine and prepare for some to lose access to financial services outside its borders, adding that businesses in Northern Ireland (a UK territory) should seek help from Ireland.

If it becomes clear that the UK won’t get a deal, an alternative would be for the government to revoke Article 50. That would stop the timer on the Brexit negotiations, keep the UK in the EU, and thus, effectively, stop Brexit.

The trouble is that the legal text of the Article doesn’t say whether the UK can do so unilaterally (i.e., without getting approval from the remaining 27 members). That matters because, if the UK didn’t have the power, it’s unlikely that the rest of the EU would agree to let the UK remain in the EU after wasting two years of failing to negotiate a deal. Or those member countries might ask for concessions, such as maybe require the UK to adopt the euro if it wishes to remain in the EU.

If instead the UK did have the power to revoke Article 50 unilaterally, it could force the British prime minister to offer a genuine option to the country’s lawmakers: Is it better to leave without a deal or is it better to stop Brexit?

All this, however, depends on the legal interpretation of the Article 50 text. Maugham has been raising money from the public to try and get Europe’s highest court to rule on that interpretation. In February 2017, he filed a case in a court in Ireland. But in May that year the Irish court said, in effect, that it didn’t want to be part of a struggle between the UK and the EU. (You can read about the details of the case in an in-depth Quartz feature.)

In June this year, after raising more money from the public, the Good Law Project, which Maugham leads, filed a case on the revokability of Article 50 in a Scottish court. On Friday (Sep. 21), the court finally agreed with Maugham, and it has now sent the case to the European Court of Justice. The court’s ruling will decide, once and for all, whether the UK has the power to unilaterally revoke Article 50.

When will we know the final answer? “I’ve been given indications that it will be before Christmas,” says Maugham. That might be a welcome gift for many.