How do the Danes go through above Finland when they are both on 3 points?

Finland beat them 1-0 and I thought it was head to head before goal difference?

Danes go 3-1 as I type this!! Would be great for them to go through after the first game!