summaryrefslogtreecommitdiff
path: root/python/vyos
diff options
context:
space:
mode:
authorThomas Mangin <thomas.mangin@exa.net.uk>2020-03-04 12:36:19 +0000
committerThomas Mangin <thomas.mangin@exa.net.uk>2020-03-04 15:06:07 +0000
commit7a752c0287651876809ced750319eec9eb125e07 (patch)
tree231bf6a070fc2258553ff247cc3f66e5998ae2e4 /python/vyos
parent5cb485c2fa6e551b9ff8949e9429abd02996cb78 (diff)
downloadvyos-1x-7a752c0287651876809ced750319eec9eb125e07.tar.gz
vyos-1x-7a752c0287651876809ced750319eec9eb125e07.zip
ifconfig: T2057: fix various typos
Diffstat (limited to 'python/vyos')
-rw-r--r--python/vyos/ifconfig.py15
1 files changed, 6 insertions, 9 deletions
diff --git a/python/vyos/ifconfig.py b/python/vyos/ifconfig.py
index 389f6072f..1a2fad46f 100644
--- a/python/vyos/ifconfig.py
+++ b/python/vyos/ifconfig.py
@@ -1036,32 +1036,31 @@ class BridgeIf(Interface):
_sysfs_set = {**Interface._sysfs_set, **{
'ageing_time': {
'validate': assert_positive,
- 'convert': lambda time: int(time) * 100,
+ 'convert': lambda t: int(t) * 100,
'location': '/sys/class/net/{ifname}/bridge/ageing_time',
},
'forward_delay': {
'validate': assert_positive,
- 'convert': lambda time: int(time) * 100,
+ 'convert': lambda t: int(t) * 100,
'location': '/sys/class/net/{ifname}/bridge/forward_delay',
},
'hello_time': {
'validate': assert_positive,
- 'convert': lambda time: int(time) * 100,
+ 'convert': lambda t: int(t) * 100,
'location': '/sys/class/net/{ifname}/bridge/hello_time',
},
'max_age': {
'validate': assert_positive,
- 'convert': lambda time: int(time) * 100,
+ 'convert': lambda t: int(t) * 100,
'location': '/sys/class/net/{ifname}/bridge/max_age',
},
'priority': {
'validate': assert_positive,
- 'convert': lambda time: int(time) * 100,
'location': '/sys/class/net/{ifname}/bridge/priority',
},
'stp': {
'validate': assert_boolean,
- 'location': '/sys/class/net/{ifconfig}/bridge/stp_state',
+ 'location': '/sys/class/net/{ifname}/bridge/stp_state',
},
'multicast_querier': {
'validate': assert_boolean,
@@ -1071,11 +1070,9 @@ class BridgeIf(Interface):
_command_set = {**Interface._command_set, **{
'add_port': {
- 'validate': assert_boolean,
'shellcmd': 'ip link set dev {value} master {ifname}',
},
'del_port': {
- 'validate': assert_boolean,
'shellcmd': 'ip link set dev {value} nomaster',
},
}}
@@ -1140,7 +1137,7 @@ class BridgeIf(Interface):
>>> from vyos.ifconfig import BridgeIf
>>> BridgeIf('br0').set_priority(8192)
"""
- self.set_interface('priority', time)
+ self.set_interface('priority', priority)
def set_stp(self, state):
"""