Livingston secured a place in the top six as they picked up their first win in seven games with a 2-1 home triumph over Hamilton Accies.
The three points mean that the Lions will finish in the top half of the Premiership for the second successive season - the first time that's happened in the club's history.
Livingston took the lead on 16 minutes after a moment of sheer genius from Jay Emmanuel-Thomas. Neat play down the right flank led to Nicky Devlin playing a one-two with skipper Marvin Bartley before finding the striker who promptly flicked the ball up to himself and, on the swivel, volleyed home into the top corner.
Having given his side the lead, the Englishman gave the ball away for Accies' equaliser on the half hour mark. Caught in possession just inside his own half, the ball fell kindly to Callum Smith. The youngster strode forward before unleashing a fizzing effort from 25 yards that found the bottom corner beyond the outstretched Robby McCrorie.
Parity didn't last long, though, as Scott Pittman bundled the ball home from close range six minutes later. Devlin, who had a brilliant afternoon tearing down the right flank, saw his cross deflected by Lee Hodson with Pittman on hand to turn the ball home.
It was the midfielder's 15th top flight goal for the Lions - a figure that ties him with Derek Lilley and Burton O'Brien for most in the club's history.
Both sides showed plenty of fight and endeavour after the break but chances were very much at a premium.
With 12 minutes left on the clock, Ross Callachan got in behind the Livi defence on the right and fired across the face of goal but no team-mate was gambling at the back post for what would have been a simple tap-in.
Substitute Josh Mullin almost put the game beyond doubt in the closing stages as he rattled the crossbar from the edge of the box.
The Lions, though, would see out the remainder of the game to seal their top six place.
Livingston: McCrorie; Devlin, Fitzwater, Guthrie, Longridge; Holt, Bartley; Sibbald (Serrano 84), Pittman, Forrest (Mullin 77); Emmanuel-Thomas (Poplatnik 89). Subs not used: Maley, McMillan, Tiffoney, Ambrose, Lawson, Kabia.
Goals: Emmanuel-Thomas (16), Pittman (36).
Hamilton Academical: Fulton; Hamilton, A. Martin, Easton; Hodson (Hughes 54), Odoffin, Callachan, S. Martin, Munro; Smith (Moyo 89), Anderson. Subs not used: Gourlay, Stirling, Trafford, Stanger, Mimnaugh, Slaven, Redfern.
Goal: Smith (30)