Ecuador’s President Lenin Moreno declared a nationwide state of emergency last Thursday amid violent protests across the country over the end of fuel subsidies that have been in place for decades.

Protests erupted in the Latin American oil producer—a member of OPEC that has just announced its intention to quit the cartel—after Moreno said that the fuel subsidies that had been in place for 40 years would end.  

According to Moreno, in office since 2017, the fuel subsidy is ‘perverse ‘and has distorted Ecuador’s economy over the past few decades. The country can no longer afford the costly subsidy, the president says as he pushed through with a US$2 billion package of fiscal reforms.

The fuel subsidies cost the government of Ecuador as much as US$1.3 billion every year, according to the BBC.

The end of the subsidy, however, is more than doubling gasoline and diesel prices in Ecuador and the people are not taking it well.

Protesters erected barricades, while riot police fired tear gas at protesters in one of the most violent unrests in the South American country in the past few years.

While the government says that the subsidies need to go away to stop fuel smuggling and incentivize Ecuador’s flagging economy, people are angry that the much higher prices would significantly affect their lives and spending. Bus, truck, and taxi drivers are blocking the streets in Ecuador, demanding the government withdraw the reforms and reinstate the fuel subsidies.

The protests and the end of the subsidies come as Ecuador also announces that it would quit OPEC effective January 1, 2020, because of its fiscal problems as it seeks to raise government income and cut spending.

According to OPEC’s latest available figures, Ecuador pumped 537,000 bpd of crude oil in August.

Ecuador leaving OPEC will not have a major impact on the organization, analysts say, while Ecuador said that it would continue to support OPEC’s efforts to stabilize the oil market.