new_address = []
for item in obj.address:
if self.filter_kind(item):
- new_address.extend(item.clone(kind='housenumber', name=n) for n in self.sanitize(item.name))
+ new_address.extend(item.clone(kind='housenumber', name=n)
+ for n in self.sanitize(item.name))
else:
# Don't touch other address items.
new_address.append(item)
yield from self._regularize(hnr)
- def _regularize(self, hnr):
+ @staticmethod
+ def _regularize(hnr):
yield hnr
delimiters: Define the set of characters to be used for
splitting the list. (default: ',;')
"""
-from nominatim.errors import UsageError
from nominatim.tokenizer.sanitizers.helpers import create_split_regex
def create(func):