1
0
mirror of https://github.com/gryf/wicd.git synced 2025-12-24 23:22:27 +01:00

Fix "TypeError: cmp is an invalid keyword argument for sort()"

This commit is contained in:
Axel Beckert
2019-09-11 01:33:03 +02:00
parent c2789eb467
commit 9587c52c88

View File

@@ -48,6 +48,7 @@ import time
import threading
import os
from signal import SIGTERM
from functools import cmp_to_key
# wicd imports
from . import misc
@@ -663,7 +664,7 @@ class Wireless(Controller):
time.sleep(1)
aps = wiface.GetNetworks(essid)
aps.sort(cmp=comp, reverse=True)
aps.sort(key=cmp_to_key(comp), reverse=True)
return aps