From b39be50b011ea6e3278e9c1748cf4419a536e90f Mon Sep 17 00:00:00 2001 From: acidvegas Date: Tue, 30 May 2023 03:37:20 -0400 Subject: [PATCH] Fixed parser not handling booleans --- parser.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/parser.py b/parser.py index c8a6a74..54cd608 100644 --- a/parser.py +++ b/parser.py @@ -10,6 +10,8 @@ def parse(option, data, raw=True): data = ' '.join(line.split()[3:]) if data[:1] == ':': data = data[1:] + if type(data) == bool: + data = str(data) print(data.replace(option, f'\033[31m{option}\033[0m')) return data @@ -35,7 +37,7 @@ if len(sys.argv) >= 2: found.append(parse(option, data, raw)) elif type(data) == list: for item in data: - found.append(option, parse(item, raw)) + found.append(parse(option, item, raw)) else: for item in data: _data = data[item]