jennifer lopez vf cover Jennifer Lopez talks Marc Anthony divorce in Vanity FairFor the first time since they went public with their separation and plans to divorce, Jennifer Lopez is talking about what led to the rift with soon-to-be-ex Marc Anthony.

“To understand that a person is not good for you, or that the person is not treating you in the right way, or that he is not doing the right thing for himself — if I stay, then I am not doing the right thing for me. I love myself enough to walk away from that now,” she tells Vanity Fair in a new interview.

Anthony was once rumored to have had an extramarital dalliance with a flight attendant.

The “American Idol” judge also talks about her past relationship with P. Diddy and Ben Affleck. But despite a bumpy love life, she remains hopeful that she’ll find the right relationship.

“Sometimes it doesn’t work–and that’s sad,” she says. “But I remain an eternal optimist about love. I believe in love.”

As for Anthony, the couple has two children together, twins Max and Emme, so luckily communication between the two remains cordial.

“I will always respect Marc as a singer and performer,” says Lopez. “We actually work great together, and he was always very supportive.”