Fixed dependency issues for remove_WIDEn_N

This commit is contained in:
Bill Mitchell 2018-04-06 04:50:18 -05:00
parent 848610ae4e
commit 3e1fdce439
1 changed files with 9 additions and 1 deletions

View File

@ -1,5 +1,13 @@
from math import floor
import re
__all__=["degrees_to_ddm",
"latitude_to_ddm",
"longitude_to_ddm",
"comment_altitude",
"floor",
"remove_WIDEn_N",
]
def degrees_to_ddm(dd):
degrees = int(floor(dd))
@ -40,6 +48,6 @@ def remove_WIDEn_N(path):
path: path of parsed packet (list of strings)
returns: list of digipeaters that digipeated packet, in order
"""
path = map(lambda x: re.sub('*$', '', x), path) # Remove asterisks
path = map(lambda x: re.sub('\*$', '', x), path) # Remove asterisks
path = list(filter(lambda x: not re.match(r'WIDE[0-9\-\*]+$', x), path))
return(path)