diff --git a/modules/utils.py b/modules/utils.py index 0cd664e..17afbca 100644 --- a/modules/utils.py +++ b/modules/utils.py @@ -56,7 +56,11 @@ def configSet(key: str, value, *args: str, file: str = "config"): for arg in args: string += f'["{arg}"]' if type(value) in [str]: - string += f'["{key}"] = "{value}"' + value.replace("'", "\'").replace('"', '\"') + if len(value) < 30: + string += f'["{key}"] = "{value}"' + else: + string += f'["{key}"] = """\n{value}\n"""' else: string += f'["{key}"] = {value}' exec(string)