Don't open your ex's Facebook profile. A new error in application Facebook automatically sends friend requests when you visit a stranger's profile. The problem was only in application Facebook for mobile.
At the moment Facebook seems to have solved the problem. So you can visit (or watch) strangers' Facebook profiles without consequences.
This error was occurring so quickly that it was very hard to notice. When visiting a stranger's profile, the “Proccase friend" automatically changes to "Pending". No warning was displayed, any emerging window or anything else that indicated you sent a friend request. The only way to avoid the bug was to not visit strangers' Facebook profiles.
“We fixed a bug related to a recent app update that caused some Facebook friend requests to be sent incorrectly. We apologize for any inconvenience this may have caused." — representative of Meta
The bug was originally reported on r/Facebook subreddit. We don't know how many people were affected by this bug.