Mistakes that make us learn from

Couple of months ago I started searching on line for new friends , as that was my intention . 
I got on a few online dating sites known as Coffe and Bagle , Baddo , Match and so on . 
I began to notice the different types of males 
The Desperate 
The shy ones 
The outgoing 
So finally I gave myself a chance to meet a guy and get to know him , he's on the outgoing list .
As soon as I meet him we clicked, and kissed, 
I noticed a very strong connection between us , a few weeks later he asked me to be his girlfriend. 
As I accepted, I ignored all the red flags trying to convince myself to give myself an opportunity after 2 years being single . 
A month later I find out he is a married man , and his wife is about to have a baby . 
I was happy to have found out before falling deeply in love with a liar /cheater