It seemed like Yui mortally wounded her body in such a way that when time ran out, Daiki would wake up in his own body before his soul would die in Yui's body. Either that, or the very Cross Method is a temporary spell that was always designed to return swapped souls to their original bodies after the time limit even if one body dies during the swap.