Skip to content

Commit 717ee95

Browse files
committed
refactor: move prefix to const
1 parent 368e280 commit 717ee95

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

backend/utils/methods_handler.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
import json
22
from collections import defaultdict
33

4+
FRONT_SELECTION_PREFIX = "export const METHODS = "
5+
46

57
class Methods:
68
@staticmethod
@@ -17,8 +19,7 @@ def parse_frontend_file_to_dll_methods(
1719
):
1820
with open(front_selection_resource_path, "r") as f:
1921
content = f.read()
20-
prefix = "export const METHODS = "
21-
json_str = content[len(prefix):]
22+
json_str = content[len(FRONT_SELECTION_PREFIX):]
2223
selection_tree = json.loads(json_str)
2324

2425
dll_methods = defaultdict(list)

0 commit comments

Comments
 (0)