In the weeks leading up to the Taliban's takeover of Kabul last year, Khalil Rahman Omaid knew he was in mortal danger.
"[People] were all scared of the situation and were running to the airport," Omaid says.
"I was also thinking, 'What can I do? How can I get out?' "
It was his foreign connections that painted a target on Omaid's back - in the eyes of the Taliban, he was a traitor, and they sent him a threatening letter as a result.
"[The letter] said 'you worked with the foreigners and you must pay that cost'," Omaid explains.
"It means you will be killed."
A connection to New Zealand
During the years of Afghanistan's international occupation, Omaid was a journalist who'd done work as a fixer and translator for international news organisations.
He'd also worked for the New Zealand government: in 2018, he was recruited to work on the Operation Burnham Inquiry, which was an investigation into allegations of civilian deaths during a 2010 SAS raid of an Afghan village.
Kiwi journalist Nicky Hager (who played a pivotal role in the inquiry because of a book he'd written about the raid) tracked down Omaid to do on-the-ground interviews and research.
Hager says Omaid was "perfect for the job", which involved travelling to dangerous parts of Afghanistan to gather information.
"He was our eyes and ears, and he was fearless about it," Hager says.
A plea for help
After the inquiry wrapped up, Hager wasn't sure he would ever see Omaid again.
But in August last year, he received a request from Omaid asking for help.
"I suddenly got this email from him out of the blue, which said very modestly, 'I hope I hear from you soon' in the subject line," Hager says.
"This was the day after the Taliban had started their great push across the country. So just the next day he said, 'I'm really in trouble. I'm wondering if you could help me get to New Zealand'."
With that, Hager dropped everything to help, and he did everything he could to try to get the New Zealand government to assist Omaid.
Kiwi journalists rallied to the cause, putting their names to a letter demanding action from the then immigration minister to evacuate Omaid and his family.
The intense lobbying efforts seemed to pay off: On the same day Omaid's plight was featured in a front-page Dominion Post story, the government announced it would evacuate Afghan nationals who had helped on the Operation Burnham Inquiry.
The final hurdles
It wasn't over yet though - while Omaid and his family received New Zealand visas, they didn't make it on to one of the few New Zealand evacuation flights.
"A certain point came during the last crucial week. This was the week, which ended with a bomb going off at Kabul Airport, all the planes stopping, the gates crashing shut," Hager says.
"During that week, I said to him, 'I'm not actually sure this is going to work. What other ways are there to get you out of the country? Because you've just got to get out of the country.' "
Omaid managed to find a way for his family to get to the airport safely, with only the clothes they wore on their backs and a blanket.
For three whole days, they stood by at the crowded Kabul Airport, praying desperately for a flight out.
"I was waiting every second and every moment that we are going to get news that we should find a flight," Omaid says.
In the end, they made it onto one of the last commercial flights to leave Afghanistan - which took them to Uganda, of all places - and it took another three months for them to get to New Zealand.
But at least they knew they were finally safe.
A new life in Wellington
This December will mark the one-year anniversary of Omaid and his family living in Aotearoa.
He says they're all happy here: His young children are attending a local daycare, and he and his wife are doing courses to improve their English.