The fact that some pirates wore eye patches most likely had nothing to do with a missing eye, and everything to do with being able to see—specifically, above decks and below them.
Jim Sheedy, a doctor of vision science and director of the Vision Performance Institute at Oregon's Pacific University, told the Wall Street Journal that while the eyes adapt quickly when going from darkness to light, studies have shown that it can take up to 25 minutes for them to adapt when going from bright light to darkness, which "requires the regeneration of photo pigments."
Pirates frequently had to move above and below decks, from daylight to near darkness, and Sheedy says the smart ones "wore a patch over one eye to keep it dark-adapted outside." When the pirate went below decks, he could switch the patch to the outdoor eye and see in the darkness easily (potentially to fight while boarding and plundering another vessel).
Arrrr We Sure?
Though there are no first-person sources from history that state this as fact, there's no question that keeping one eye dark-adapted works. MythBusters tested this hypothesis in their pirate special in 2007 and determined that it was plausible (only the lack of historical sources kept it from being confirmed). At least one military manual for pilots pointed out that "Even though a bright light may shine in one eye, the other will retain its dark adaptation, if it is protected from the light. This is a useful bit of information, because a flyer can preserve dark adaptation in one eye by simply closing it." Even the FAA recommends that "a pilot should close one eye when using a light to preserve some degree of night vision."