In today's social media world where people are willing to post any gossip on the internet for some meaningless likes / points, I think its actually prudent to measure your words carefully before you voice them. Especially if the law is involved.
If you’re afraid that your friend will share on social media your name and your state of happiness about your previous job, May be they aren’t great friends.