Both situations where fear can let the dark side in.
Just like Anakin's fall was never to do with things right in front of him, but fear for things that might be in the future.
It's almost like it's a central theme of the whole saga or something.....
Go and watch the film again. Vader doesn't start taunting until the fight has begun, and when he does it makes Luke angry, he abandons technique and fights with raw force and violence for the first time in the whole series. And it's only when he does that that he has the strength to overpower Vader.
And that's what the Dark Side is.
Seriously, go and actually watch the film you're talking about.
Luke briefly draws on the dark side out of fear of what might happen, and only masters himself after a reminder of what it cost him last time. And there is nothing in the film which demonstrates that he would not do so again because it's the last thing of consequence he actually does in the film.
Apart from Luke's repeatedly established tendency to make poor decisions out of fear, which is explicitly the path to the dark side.The irony. Look, if we go by what's in the movies only, nothing in The Return of the Jedi indicates that Luke would kill his nephew in cold blood for future crimes.
Luke felt the temptation of the dark side once again when he looked into Ben Solo, and once again he gave in to fear for a brief moment, as he has done many times before. This time he recovered himself too late and it wasn't something he could fix.