I don't agree with that statement. Yes, Romeo and Juliet fall madly in love with each other and probably make some dumb decisions, but I don't think that the message of their passion is a warning against it. Their love, relationship, and deaths are tragic to audiences because of the senseless nature of the feud between the Capulets and Montagues.
If you buy into Romeo and Juliet being truly in love with each other, then their relationship could have been used as a mechanism to heal the two warring families and bring them back to peace. That's what Friar Lawrence thought, anyway, and voiced it in Act 2, Scene 3.
For this alliance may so happy prove
To turn your households’ rancour to pure love
That's why I feel the play isn't so much about the danger of their love. If anything, their love should have been a unifying force. Not just between Romeo and Juliet, but between their families. The main problem though, as I see it, wasn't the fact that they were in love. The problem was that their families' feud was so ingrained in everybody that nobody could see past it. Capulet categorically refuses to even entertain the idea of Juliet being in love with Romeo simply because he is a Montague. Shakespeare frequently has family members deny love to a daughter for superficial reasons like that. Shylock does it in "The Merchant of Venice" for religious reasons, and it happens in "Othello" for race reasons. I have never felt that Shakespeare is warning audiences to not fall in love with people from the "other side." I have always felt Shakespeare is warning against being extremely closed-minded. Romeo and Juliet's uncontrolled passion simply serves to show an extreme polarity in the warring families in the play.