neingeist
/
smstool
Archived
1
0
Fork 0

Refine cell phone regex

master
neingeist 20 years ago
parent 0240cbbb66
commit eddd78688a

@ -26,8 +26,8 @@ class EvolutionCells:
for e in db[k].split('\r\n'):
if re.search("^FN:", e):
name = re.sub("^FN:", "", e)
if re.search("^TEL;TYPE=CELL:", e):
cell = re.sub("^TEL;TYPE=CELL:", "", e)
if re.search("^\.?TEL;TYPE=CELL.*?:", e):
cell = re.sub("^\.?TEL;TYPE=CELL.*?:", "", e)
if cell != "":
contacts[name] = cell