That's called coveting.
It's one of the 10 commandments.
They had to wait several months before they could annul the wedding for the sake of beleivability.
It's just a question of if they got around to it despite that there was a war going on.
If you squint, Kirk and Spock were engaged to the same bird in Amok Time. So they wer each committing adultery on each other equally.
How married did Kirk get to Miramanee? Or did she die in the end the paradise Syndrome?
Didn't Kirk make out with Kang's wife Mara in Day of the Dove, and he certianly kissed his way betwixt those married Kelvans who didn't know about that Earth custom called Kissing in By Any Other Name.