The discovery of the role cowpox can play in preventing smallpox infection was a total accident. (Not the one you think)
Smallpox inoculation was becoming widespread in England, and doctors checked for a "successful" inoculation by looking for smallpox pustules. If an inoculation was deemed unsuccessful the patient had to be reinoculated until a reaction was observed. One day after an unsuccessful inoculation, a farmer, grasping at straws, mentioned that he had recently had cowpox. This triggered the doctor's curiosity resulting in research into the instances of patients, (particularly farm workers) who had had cowpox before having no reaction to the smallpox inoculation.
Many doctors collected a lot of data, and had many discussions before hypothesising that recent cowpox infection could prevent smallpox infection.
While Edward Jenner did test the hypothesis, the story about him noticing the unblemished milkmaids and having a Eureka! moment, is an entirely fictional account designed to make immunisations more appealing to the general public.
The last smallpox epidemic in the US was in 1949.
Seth Gabel who played Pastor Walter also played Cotton Mather a co-pastor on the show Salem.
As inoculation with smallpox was already becoming common, the discovery of cowpox as an alternative was of interest to the scientific community, but not the game changer it is believed to be now.