How long have you had the fish?
What species is it, and what are it's tankmates and tank size?
What did the eye look like prior to falling out?
Was the other eye affected at all?
There could be a lot of reasons this happened, but we'll need to narrow down the list.