mirror of
https://git.quad4.io/RNS-Things/MeshChatX.git
synced 2026-10-22 11:32:30 +00:00
fix(parser): add validation for interface configuration to ensure it is a dictionary
This commit is contained in:
1 file changed
+6
@@ -30,6 +30,12 @@ class InterfaceConfigParser:
|
||||
for interface_name in config_interfaces:
|
||||
# ensure interface has a name
|
||||
interface_config = config_interfaces[interface_name]
|
||||
if not isinstance(interface_config, dict):
|
||||
print(
|
||||
f"Skipping invalid interface configuration for {interface_name}: expected dict, got {type(interface_config)}",
|
||||
)
|
||||
continue
|
||||
|
||||
interface_config["name"] = interface_name
|
||||
interfaces.append(interface_config)
|
||||
|
||||
|
||||
Reference in new issue
Block a user