Skip to content
Snippets Groups Projects

Draft: Implement initial functionality

Closed Martin Matějek requested to merge dev into master
@@ -100,7 +100,7 @@ class WWanUci:
else:
extra_auth = {"auth_type": "none"}
enabled = WWanUci._is_designated_as_wan(if_name)
enabled = NetworksUci.is_designated_as_wan(if_name)
return {
"id": dev_no,
@@ -181,16 +181,6 @@ class WWanUci:
return int(match.group(1))
@staticmethod
def _is_designated_as_wan(if_name: str) -> bool:
"""Check whether given interface is designated as WAN."""
wan_interfaces = NetworksUci.get_active_wan_interfaces()
if not wan_interfaces:
return False
# NOTE: is set really needed here?
return set(wan_interfaces) == {if_name}
class WWanCmd(BaseCmdLine):
@staticmethod