summaryrefslogtreecommitdiff
path: root/python
diff options
context:
space:
mode:
authorChristian Breunig <christian@breunig.cc>2023-08-07 22:52:26 +0200
committerChristian Breunig <christian@breunig.cc>2023-08-07 23:05:12 +0200
commitcfc58824138595920717ea8400fd1cb90cc62dae (patch)
treef6826691e55cdc71f5a03c304c9b62493794271e /python
parent91144f29f0cd636a30a27efcdc1d9a389e2c5071 (diff)
downloadvyos-1x-cfc58824138595920717ea8400fd1cb90cc62dae.tar.gz
vyos-1x-cfc58824138595920717ea8400fd1cb90cc62dae.zip
dhcp(v6): T5428: add proper return statements in set_dhcp(v6) methods
Diffstat (limited to 'python')
-rw-r--r--python/vyos/ifconfig/interface.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/python/vyos/ifconfig/interface.py b/python/vyos/ifconfig/interface.py
index 8ed5cb114..75c5f27a9 100644
--- a/python/vyos/ifconfig/interface.py
+++ b/python/vyos/ifconfig/interface.py
@@ -1275,7 +1275,6 @@ class Interface(Control):
# running, but it should be running (e.g. on system startup)
if 'dhcp_options_changed' in self.config or not is_systemd_service_active(systemd_service):
return self._cmd(f'systemctl restart {systemd_service}')
- return None
else:
if is_systemd_service_active(systemd_service):
self._cmd(f'systemctl stop {systemd_service}')
@@ -1284,6 +1283,7 @@ class Interface(Control):
if os.path.isfile(file):
os.remove(file)
+ return None
def set_dhcpv6(self, enable):
"""
@@ -1317,6 +1317,8 @@ class Interface(Control):
if os.path.isfile(config_file):
os.remove(config_file)
+ return None
+
def set_mirror_redirect(self):
# Please refer to the document for details
# - https://man7.org/linux/man-pages/man8/tc.8.html