From 144379775ae8efde4f3290fa08c528977824b285 Mon Sep 17 00:00:00 2001 From: Christian Poessinger Date: Tue, 3 Sep 2019 12:49:33 +0200 Subject: Python/ifconfig: T1556: bridge: no need to manually generate an exception --- python/vyos/ifconfig.py | 6 ------ 1 file changed, 6 deletions(-) (limited to 'python/vyos') diff --git a/python/vyos/ifconfig.py b/python/vyos/ifconfig.py index 786753b8c..b25d84f26 100644 --- a/python/vyos/ifconfig.py +++ b/python/vyos/ifconfig.py @@ -907,9 +907,6 @@ class BridgeIf(Interface): >>> BridgeIf('br0').add_port('eth0') >>> BridgeIf('br0').add_port('eth1') """ - if not interface: - raise ValueError('No interface address specified') - cmd = 'ip link set dev "{}" master "{}"'.format(interface, self._ifname) self._cmd(cmd) @@ -923,9 +920,6 @@ class BridgeIf(Interface): >>> from vyos.ifconfig import Interface >>> BridgeIf('br0').del_port('eth1') """ - if not interface: - raise ValueError('No interface address specified') - cmd = 'ip link set dev "{}" nomaster'.format(interface) self._cmd(cmd) -- cgit v1.2.3