summaryrefslogtreecommitdiff
path: root/src/conf_mode/interface-wireguard.py
diff options
context:
space:
mode:
Diffstat (limited to 'src/conf_mode/interface-wireguard.py')
-rwxr-xr-xsrc/conf_mode/interface-wireguard.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/conf_mode/interface-wireguard.py b/src/conf_mode/interface-wireguard.py
index 7254e153f..3fd29ad4d 100755
--- a/src/conf_mode/interface-wireguard.py
+++ b/src/conf_mode/interface-wireguard.py
@@ -173,11 +173,11 @@ def apply(c):
# interface state
if c[ifname]['state'] == 'disable':
sl.syslog(sl.LOG_NOTICE, "disable interface " + ifname)
- intfc.state = 'down'
+ intfc.set_state('down')
else:
- if not intfc.state == 'up':
+ if not intfc.get_state() == 'up':
sl.syslog(sl.LOG_NOTICE, "enable interface " + ifname)
- intfc.state = 'up'
+ intfc.set_state('up')
# IP address
if not c_eff.exists_effective(ifname + ' address'):