From 4744e8cf5f84f70d955c6df07c6f97541406a7d3 Mon Sep 17 00:00:00 2001 From: Hay1tsme Date: Tue, 8 Aug 2023 10:24:28 -0400 Subject: [PATCH] add ip checking config options --- core/config.py | 12 ++++++++++++ example_config/core.yaml | 2 ++ 2 files changed, 14 insertions(+) diff --git a/core/config.py b/core/config.py index 8b85353..3376c3c 100644 --- a/core/config.py +++ b/core/config.py @@ -48,6 +48,18 @@ class ServerConfig: self.__config, "core", "server", "log_dir", default="logs" ) + @property + def check_arcade_ip(self) -> bool: + return CoreConfig.get_config_field( + self.__config, "core", "server", "check_arcade_ip", default=False + ) + + @property + def strict_ip_checking(self) -> bool: + return CoreConfig.get_config_field( + self.__config, "core", "server", "strict_ip_checking", default=False + ) + class TitleConfig: def __init__(self, parent_config: "CoreConfig") -> None: diff --git a/example_config/core.yaml b/example_config/core.yaml index ebf99f1..8d78008 100644 --- a/example_config/core.yaml +++ b/example_config/core.yaml @@ -6,6 +6,8 @@ server: is_develop: True threading: False log_dir: "logs" + check_arcade_ip: False + strict_ip_checking: False title: loglevel: "info"