Even if you’re pretty sure a friend can’t go to an event, invite them anyway.
Your friend will greatly appreciate you thinking of them, and may also be able to clear their schedule to allow them to go.
This also prevents said friend from feeling left out, and they can’t be angry for not being invited, should someone post things on social media or them just find out in general.