A superb finish from Michael Duffy turned the tide as Dundalk overcame UCD 3-1 in Belfield to regain second spot in the Premier Division.

The champions had to do it the hard way after falling behind to an early Yoyo Mahdy strike as Patrick Hoban equalised from the spot before Derryman Duffy settled the tie.

Dean Jarvis replaced Dane Massey in the only change from Dundalk’s 3-0 win over Finn Harps while UCD boss Collie O’Neill made three, including top scorer Conor Davis’ first start in seven weeks.

And the former Reading striker – playing in a deeper role to accommodate the in-form Yoyo Mahdy – proved the impetus for the game’s opening goal after 11 minutes.

Davis split the Dundalk defence with an impeccably-weighted pass and Mahdy was never likely to miss one-on-one with Gary Rogers.

The lead lasted just four minutes, however, as Daniel Kelly was fouled in the box by Paul Doyle, and Hoban hit the net from the spot to equal Joey Donnelly’s club record of 69 goals for the Lilywhites.

Patrick Hoban slamming home the penalty which saw him equal Joey Donnelly's goalscoring record for the club

Rogers showed good reflexes to deny Ireland under-21 star Neil Farrugia’s attempt to put UCD back in front, while Hoban passed up a chance to take the record outright as he headed at Conor Kearns.

A beautifully-struck curling shot from another former Student in Jamie McGrath had the crowd on their feet, but his shot from the edge of the box just cleared the far post.

Kearns had to be alert to tip a rasping long-range effort from Chris Shields over the bar before the break, and there was controversy when Duffy had the ball in the net as the half-time whistle blew.

The Students had done well to clear a corner and Damien McGraith’s whistle sounded moments before Duffy pulled the trigger, and Kearns had already stopped playing when the net bulged.

Former UCD man Jamie McGrath tussles for the ball with Conor Davis and Timmy Molloy

Dundalk and Duffy got the goal their play merited five minutes into the second half when the winger showed great feet to round Kearns and smash home from a tight angle.

Hoban thought he’d won another penalty two minutes later when he nicked the ball past Kearns but, rather harshly, he was booked for diving when it looked as if there had been some contact.

UCD were a much tighter outfit than they were in Friday’s 3-0 defeat to Bohemians but they wilted in the second half as the Lilywhites’ superior fitness showed.

And Vinny Perth’s side made the points – and second place – safe in injury time when Georgie Kelly netted from close range and the substitute made a point of not celebrating against his former club.

UCD: Kearns; Tobin, Collins, Scales, Doyle; O’Neill, Molloy, Davis (O’Farrell 80); McDonald (McClelland 69), Farrugia, Mahdy.

Dundalk: Rogers; Gannon, Gartland, Hoare, Jarvis; Shields, McEleney (Mountney 75), McGrath; D Kelly (Flores 86), Duffy, Hoban (G Kelly 80).

Referee: Damien McGraith (Mayo).