You marry until "death do you part".
If one of you becomes undead - a vampire or a zombie or a mummy or a ghost, for example, is that a form of death that breaks the marriage bond? Is there are distinction between the impact those possibilities, respectively, could have on marriage? Perhaps "brain dead" and not "heart dead" is what matters. Perhaps you still need to be corporal?
Of course, if you are Mormon, you "marry for eternity" and presumably the transformation to undead status doesn't matter.
Could it be that Mormons were familiar with the undead and saw how immoral it was to end a marriage just because one of the parties was dead?
Probably not, but it is an interesting theory.