Skip to content

Commit de0e740

Browse files
sambacc: rename check_config_data to take it private
The check_config_data function is not used outside of config.py. It is safe to make private so this patch does so. This will make future changes to the file clearer. Signed-off-by: John Mulligan <[email protected]>
1 parent 2b4741d commit de0e740

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

sambacc/config.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,11 +64,11 @@ def read_config_files(fnames: list[str]) -> GlobalConfig:
6464
# we read nothing! don't proceed
6565
raise ValueError(f"None of the config file paths exist: {fnames}")
6666
# Verify that we loaded something
67-
check_config_data(gconfig.data)
67+
_check_config_data(gconfig.data)
6868
return gconfig
6969

7070

71-
def check_config_data(data: dict[str, typing.Any]) -> dict[str, typing.Any]:
71+
def _check_config_data(data: dict[str, typing.Any]) -> dict[str, typing.Any]:
7272
"""Return the config data or raise a ValueError if the config
7373
is invalid or incomplete.
7474
"""
@@ -96,7 +96,7 @@ def __init__(self, source: typing.Optional[typing.IO] = None) -> None:
9696
self.load(source)
9797

9898
def load(self, source: typing.IO) -> None:
99-
data = check_config_data(json.load(source))
99+
data = _check_config_data(json.load(source))
100100
self.data.update(data)
101101

102102
def get(self, ident: str) -> InstanceConfig:

0 commit comments

Comments
 (0)