Hong Kong’s judicial independence is being questioned following the unexpected resignation of a foreign judge from the city’s top court who cited the city’s controversial new national security law as the reason for his departure.

Announced in the government gazette Sept. 18, the departure of Justice James Spigelman from the Court of Final Appeal came two years before his tenure was set to end. The resignation, which happened Sept. 2, took place just a day after the city’s embattled leader, Carrie Lam, said there was no “separation of powers” in Hong Kong’s constitutional framework, following the revelation that the phrase had been removed from school textbooks.