Before he realised that Xiao Yan Zi wasn't his daughter, Qian Long suggested that he betroth Xiao Yan Zi to Er Kang. In the end, considering the wedding mix-up, it means that Xiao Yan Zi did literally marry Er Kang like he wanted. Not sure if this is Fridge Horror or Fridge Brilliance, but also a Brick Joke.
Of course, since Yong Qi really can't marry Zi Wei, they had to switch and do the wedding ceremony all over again.
Fridge Horror: Xia Yu He raised Zi Wei as an unmarried single mother at a time when women were shamed and prosecuted for this kind of behaviour. It makes you think how really humiliating and miserable Zi Wei's childhood was. It was touched on in the series, but never explored or stated in full.