diff --git a/sarracenia/bulletin.py b/sarracenia/bulletin.py index 2e15e0361..c92e7f408 100644 --- a/sarracenia/bulletin.py +++ b/sarracenia/bulletin.py @@ -1,5 +1,6 @@ import logging import time +import re from base64 import b64decode logger = logging.getLogger(__name__) @@ -157,6 +158,11 @@ def getStation(self, data): else : station = '' + # Added to SR3 + # The station needs to be alphanumeric, between 3 and 5 characters. If not, don't assign a station + if re.search('^[a-zA-Z0-9]{3,5}$', station) == None: + station = '' + return station