There are people who wait until you get married to reveal their ugly sides. Or they just think they got you now and they get comfortable and careless.
Perhaps they go back to flirting with people out there or they reconnect with their ex. Or they had hidden a child from you. Or they were married or in the so-called ‘come stay marriage’ with someone. What do you do when this happens?
About hiding a child or a previous marriage that’s outright dishonesty and conmanship. You’re not to condone it by any means because you can no longer trust that person.

Even in commercial law if someone withholds material information that touches on the contract you’re signing, once you discover that information you’re entitled to walk out of that contract. Of course, they will say they hid the information ‘not to lose you.’ But if someone gets you by dishonesty they don’t have you yet. They denied you the chance to make an informed choice.
So how much of their past do you expect them to disclose? All material or relevant information has a significant bearing on their life today. A child definitely does that, and so does a previous marriage. It’s a record that affects their reputation and that can embarrass you if people know it and you don’t.

About getting back with exes or flirting with people, many people do this to test your boundaries. Simply make it clear that you will not put up with disrespect and disloyalty and you will happily walk out without a second thought. And you won’t just be saying it to threaten them.
You need to be mentally ready to protect yourself against abuse and disrespect by all means even if that means being alone.