Dundee United boss Ray McKinnon revealed he was about to substitute Simon Murray before the striker grabbed a crucial winner against Dunfermline.
Shortly after his 78th-minute strike, Murray was replaced by Blair Spittal for the closing minutes.
And Ray revealed the decision to take him off was taken before he struck.
He said: “We were just about to take Simon off and bring Blair on.
“He’s got himself back into the team and he tends to pop up with a goal here and there, so I’m delighted for him because he works hard.”
The United boss admitted he thought a winner against Dunfermline was not going to come.
But Murray’s late strike left Ray delighted.
“We missed a few chances and it was reaching the point where I thought it wasn’t going to come,” he said.
“Sometimes you get that feeling it’s not going to be your night and that’s what I was beginning to think.”
And while the first clash of two between the teams this week was no classic, he felt there could be no argument United deserved the points.
“It was a scrappy game and there wasn’t any fluency.
“We had to be very patient. The guys are learning patience is the key, they kept going about their business well and squandered a few half-chances but ultimately they got their reward.”
United were a man up for 51 minutes after Nate Wedderburn was red carded for a tackle on Tony Andreu.
Not only did Ray believe referee Don Robertson made the right call, he was relieved Andreu was not badly hurt in the tackle.
“I had a good view of it and it was a bad tackle. The ref got it spot on. It was one that could have led to a serious injury and I’m glad Tony is OK.”
Meanwhile, Lewis Toshney is set to start when United and the Pars meet at East End Park in the Irn-Bru Cup on Saturday.
Toshney has been missing since damaging ligaments in the draw at Hibs early last month.
There was encouraging news as well about Paul Dixon, who was carried off at Queen of the South last Saturday because of a knee injury.
Initially it was feared he might be out for at least six weeks but he could be back early.
“He’s still going to be out for a while but the doc has had a look at it and thinks it might not be quite as bad as we thought.
“It might mean it more like four rather than six weeks.”