Fierce fighting in Pakistan is harming and helping the country’s drive to eradicate polio.

With cases steadily decreasing in Nigeria, the only other persistent global hot spot, Pakistan is becoming the virus’s last refuge; 117 cases of polio paralysis have been found this year, up from 25 by this time last year. And in three months of fighting between the armed forces and the Taliban, nearly a million people have been displaced, spreading the virus, according to Unicef.

But the military operations can be “a blessing in disguise,” in the words of the Federation of Islamic Medical Associations, which wants the disease eliminated.

Most cases are in the rural Waziristan region, where leaders of some Taliban factions have banned vaccinations since 2012. As refugees flee, they often encounter polio vaccinators, who have given two million doses at roadside posts in parts of Waziristan now controlled by the army and in cities to which people from the region have fled.

However, cases do appear elsewhere, including just across the Afghan border and in distant urban neighborhoods where people from Waziristan now live.