From d684cd0360fdfc503386856c2b0b302935f74c0f Mon Sep 17 00:00:00 2001 From: crp3844 Date: Wed, 7 Sep 2022 10:32:25 -0400 Subject: [PATCH] switch from a match to if else --- bitwardenBackup.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/bitwardenBackup.py b/bitwardenBackup.py index 48dff21..74ed678 100644 --- a/bitwardenBackup.py +++ b/bitwardenBackup.py @@ -148,11 +148,11 @@ def encrypt(client, data): def decrypt(client, data): array_json = base64.b64decode(data) array = json.loads(array_json) - match array['version']: - case 1: - decrypt_v1(client, data) - case _: - logger.error("Unable to detemine encryption version.") + if array['version'] == 1: + decrypt_v1(client, data) + else: + logger.error("Unable to detemine encryption version.") + def decrypt_v1(client, data): try: