hotfix: fixed qr code parsing

This commit is contained in:
Adam Saudagar 2022-05-29 20:44:38 +05:30
parent 3fbc67c49b
commit 3b2b23b8d9
2 changed files with 2 additions and 2 deletions

View File

@ -8,4 +8,4 @@ lam2 = ("LibAddonMenu-2.0", "https://www.esoui.com/downloads/dl7/LibAddonMenu-2.
fishyqr = ("FishyQR", "https://github.com/fishyboteso/FishyQR/releases/download/v1.2.0/FishyQR.zip", 120)
libgps = ("LibGPS", "https://cdn.esoui.com/downloads/file601/LibGPS_3_0_3.zip", 30)
version = "0.5.11"
version = "0.5.12"

View File

@ -41,7 +41,7 @@ def get_values_from_image(img):
def parse_qr_code(code):
if not code:
return None
match = re.match(r'^(\d+\.\d+),(\d+\.\d+),(\d+),(\d+)$', code)
match = re.match(r'^(-?\d+\.\d+),(-?\d+\.\d+),(-?\d+),(\d+)$', code)
if not match:
logging.warning(f"qr code is not what was expected {code}")
return None