[fix] checking for components

This commit is contained in:
Al
2016-09-08 03:19:10 -04:00
parent 769a65b808
commit 170e8d74d8

View File

@@ -476,6 +476,7 @@ class OpenAddressesFormatter(object):
if rand_val < place_and_postcode_probability:
components = self.components.drop_postcode(components)
if components:
formatted = self.formatter.format_address(components, country, language=language,
minimal_only=False, tag_components=tag_components)
yield (language, country, formatted)