From 59213e814568a17c678ac8917239b22d33ddd1fa Mon Sep 17 00:00:00 2001 From: Lu Baumann Date: Mon, 16 Oct 2023 23:35:20 +0200 Subject: [PATCH] removed match to allow older python versions --- patch_xkb.py | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/patch_xkb.py b/patch_xkb.py index f3d6cb9..840061b 100755 --- a/patch_xkb.py +++ b/patch_xkb.py @@ -10,16 +10,15 @@ def brackets(text): res = 0 slash = 0 for i in text: - match i: - case "/": - slash += 1 - if slash == 2: - break - continue - case "{": - res += 1 - case "}": - res -= 1 + if i == "/": + slash += 1 + if slash == 2: + break + continue + if i == "{": + res += 1 + if i == "}": + res -= 1 slash = 0 return res