How do you know it won't hit the moon?
Using the same basic orbital calculation that let us send a dozen or so space vessels to the moon rather than off into the sun or something. We've become pretty good at telling where the moon will be at any given time. Maybe there are even "Full moon" days written in your calendar. They are when the moon and sun are in roughly opposite directions from us.