mirror of
https://github.com/KnugiHK/WhatsApp-Chat-Exporter.git
synced 2026-04-25 15:31:38 +00:00
ignoreUnreadable line in vcard #173
This makes multi line entry in vcard being ignored.
This commit is contained in:
@@ -36,7 +36,7 @@ class ContactsFromVCards:
|
|||||||
def read_vcards_file(vcf_file_path, default_country_code: str):
|
def read_vcards_file(vcf_file_path, default_country_code: str):
|
||||||
contacts = []
|
contacts = []
|
||||||
with open(vcf_file_path, mode="r", encoding="utf-8") as f:
|
with open(vcf_file_path, mode="r", encoding="utf-8") as f:
|
||||||
reader = vobject.readComponents(f)
|
reader = vobject.readComponents(f, ignoreUnreadable=True)
|
||||||
for row in reader:
|
for row in reader:
|
||||||
if hasattr(row, 'fn'):
|
if hasattr(row, 'fn'):
|
||||||
name = str(row.fn.value)
|
name = str(row.fn.value)
|
||||||
|
|||||||
Reference in New Issue
Block a user