mucus plug?

How do you know if you lost it at 24 weeks? Had some discharge today, it was small but sticky.. had sex two days ago but idk if it would be from that..