mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2025-12-28 12:10:10 +01:00
libnm/tests: fix GetAccessPoints() in test-networkmanager-service.py for hidden APs
There was a bug checking for "if a.ssid():". Refactor the whole line to use a list comprehension.
This commit is contained in:
parent
66ced4de56
commit
954c744bc0
1 changed files with 1 additions and 5 deletions
|
|
@ -356,11 +356,7 @@ class WifiDevice(Device):
|
|||
@dbus.service.method(dbus_interface=IFACE_WIFI, in_signature='', out_signature='ao')
|
||||
def GetAccessPoints(self):
|
||||
# only include non-hidden APs
|
||||
array = []
|
||||
for a in self.aps:
|
||||
if a.ssid():
|
||||
array.append(a)
|
||||
return to_path_array(array)
|
||||
return to_path_array([a for a in self.aps if a.ssid])
|
||||
|
||||
@dbus.service.method(dbus_interface=IFACE_WIFI, in_signature='', out_signature='ao')
|
||||
def GetAllAccessPoints(self):
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue