Afghanistan was spared the devastation caused by a massive October 8 earthquake in neighboring Pakistan and in India .