A dramatic late winner by George Moncur helped Luton stage an incredible fightback to defeat fellow relegation strugglers Wigan 2-1 at Kenilworth Road.
With the game entering stoppage time and Town having only just restored parity through substitute Callum McManaman's goal against his former side, fellow replacement Moncur converted from close range to lift the roof off the stadium.
It had looked like Wigan would pick up a first away victory in the Championship this term after leading through Kieffer Moore's 35th minute strike.
The hosts, eager to bounce back from a 7-0 hammering at Brentford last weekend, bossed the opening stages, Ryan Tunnicliffe denied by a fine goal-line clearance from Dujon Sterling and then Cornick heading off target.
Wigan went close after 22 minutes when leading scoring Dunkley's header from a deep cross flashed just inches past the post.
Antonee Robinson tried from range, bending wide of the post, before the Latics led after 35 minutes with Sterling sending over a fine cross and Moore rising magnificently to bullet his header beyond James Shea.
Moore then almost made it 2-0, diverting another Sterling cross just wide as Wigan looked to heap more misery on a Luton side looking short of confidence.
The visiting stopper was called upon moments later as Cornick cut the ball back for Tunnicliffe, the midfielder's shot parried to safety.
The introduction of Moncur pepped up Town's attacking options, as did former Wigan winger McManaman, the latter trying to equalise against his old club, missing the bottom corner.
However, McManaman did level with three to go, firing home at the second attempt.
Then with Latics' centre-half Dunkley dismissed for a second yellow by hauling back Cornick, Moncur kept his nerve to fire home a first goal of the season and win it for the Hatters.