Nigeria's ruling party has appointed a new chairman at a national convention meant to end infighting as it prepares to select a candidate to replace President Muhammadu Buhari in the 2023 election.
Buhari, who was first elected in 2015, spent weeks negotiating with the party's state governors and delegates to push a consensus position before the convention on Saturday.
Late Saturday night, the party agreed on Abdullahi Adamu, a senator who had been backed by Buhari to avoid more infighting, according to All Progressives Congress (APC) party electoral committee.
"I had cause to intervene in the leadership crisis which was about to cause confusion," Buhari said in a statement. "We must avoid overheating the polity and not allow our differences to tear and frustrate the party."
Political jockeying has already begun to replace Buhari as leader of Africa's most populous nation but the race remains open with several heavyweights in the running.
Thousands of delegates and supporters had packed into a stadium in the capital Abuja, where the APC sought to end the bickering that Buhari warned could undermine its success in the 2023 vote.
The appointment of a new party chairman and delegates was a final stage before primaries later this year for a presidential candidate.
Formed in an alliance of several parties in 2013, the APC managed to win in 2015 over the long-ruling People's Democratic Party (PDP), which at the time was battling its own internal splits.
Buhari, who came to power promising to bring security and fight corruption, steps down pointing to his successes in infrastructure and transport projects.
But Nigeria is still battling jihadists in its northeast and its northwest region has been hit hard by criminal gangs behind a spate of attacks and mass kidnappings.
On Saturday, an armed gang attacked Kaduna City airport, killing one security guard and briefly disrupting flights, in another escalation of bandit violence in the northwest region.
Africa's largest economy and top oil producer is recovering from the setback of the coronavirus pandemic, but recent fuel and electricity shortages have underlined cost-of-living woes for Nigerians.
Several presidential candidates have already made their ambitions known, including former Lagos State governor and APC strongman Bola Tinubu, and opposition PDP stalwart and former vice president Atiku Abubakar.
Under an unwritten agreement among elites, Nigeria's presidency is expected to rotate between a candidate from the mostly Muslim north and the predominantly Christian south.
After two terms with Buhari, a Muslim from the north, many southern leaders are pushing for the presidency to return to a candidate from their region.