Michael Murphy returned in the nick of time for Donegal as they got their promotion hopes back on track with a narrow victory over Armagh.
It was a close contest for much of the game, but Donegal took a firm grip in the final quarter, going four clear.
But they were made to sweat then to the end as Armagh threw everything at them but just came up short.
It was Murphy's introduction that had a vital bearing on the game and the Glenswilly man finished with 1-2, the goal being the big turning point of the game.
Leo McLoone was playing his 101st game for Donegal and he was a giant in the defence throughout.
It was not a place for the faint hearted in MacCumhaill Park as the wind and rain swept over the field, especially in the last ten minutes of the opening half.
But despite the conditions, the sides were serving up a good game. You could see that it mattered to both.
Armagh took an early two point lead through Jamie Clarke and a Rian O'Neill free.
But Donegal got back in the contest thanks to the urgings of Leo McLoone. Michael Langan converted two frees before the first major incident of the game on 17 minutes. After tempers cooled James Morgan of Armagh and Jason McGee saw red.
Michael Langan edged Donegal ahead but Stephen Campbell levelled. Then the first big roar as Michael Murphy came into the action.
Two superb Niall Grimley strikes, one free and one sideline, had Armagh two ahead but Eoghan Bán Gallagher cut through the Armagh defence and he fed Niall O'Donnell to fire over when the goal was on.
Jamie Clarke, causing Donegal many problems, fielded a long clearance for a mark and he took it short to Stefan Campbell to put Armagh 0-6 to 0-4 ahead.
But as the clouds opened Donegal struck for a goal. Good work by Eoghan Bán Gallagher and Ryan McHugh saw Michael Langan find Michael Murphy in space and he fired low to the net.
Almost immediately Armagh had the ball in the Donegal net but it was ruled out for an infringement to leave it 1-4 to 0-6 to the home team at half-time.
Donegal had any advantage that was going with the crossfield breeze in the second half and they doubled their lead when Jamie Brennan won a free for Ciaran Thompson pointed.
Rian O'Neill after a good break by Niall Grimley cut the lead but Michael Langan landed a free from 45m. Grimley and Langan traded further points by the 55th minute.
Michael Murphy landed a long range effort for a three point lead, the first time there was three between them in the game. Murphy then added another after a superb individual run.
Rian cut the lead to three with a minute left and two minutes into the four minutes O'Neill had it down to two. With time up they won a free and Ethan Rafferty went for goal but it went over.
Donegal: Shaun Patton; Stephen McMenamin, Brendan McCole, Caolan Ward; Ryan McHugh, Leo McLoone, Eoghan Bán Gallagher; Hugh McFadden, Caolan McGonagle; Ciaran Thompson (0-01, 0-01f), Jason McGee, Michael Langan (0-05, 0-05f); Jamie Brennan, Oisin Gallen, Niall O'Donnell (0-01). Subs: Michael Murphy (1-02) for Gallen 29; Eoin McHugh for Thompson 47; Paul Brennan for McMenamin 55
Armagh: Blaine Hughes; James Morgan, Aaron McKay, Ryan McShane; Connaire Mackin, Greg McCabe, Paul Hughes; Stephen Sheridan, Niall Grimley (0-03,0-02f,0-01s/line); Jemar Hall, Rory Grugan, Charlie Vernon; Stefan Campbell (0-02), Rian O'Neill (0-04, 0-01f), Jamie Clarke (0-01). Subs: Ryan Kennedy for R McShane ht; Ethan Rafferty (0-01,0-01f) for S Campbell 39; Mark Shields for Hall; Jarlath Og Burns for Vernon both 61; Joe McElroy for Macken 69
Referee: Martin McNally (Monaghan)