Updated

A Pakistani police officer says a judge has dismissed the case against an American FBI agent arrested over ammunition found in his luggage.

Khalid Mahmood said the judge Monday dismissed the case after police produced a letter from the Ministry of Interior attesting that the agent was allowed to carry a weapon while in Pakistan and therefore any ammunition was legal.

The agent, identified as Joel Cox, was detained May 5 after officials found ammunition in his luggage as he was preparing to board a flight to Islamabad.

The arrest had the potential to test relations between uneasy allies, Pakistan and the U.S. but the tension was alleviated when Cox was granted bail on May 8.