Skip to content

Commit 038fccc

Browse files
committed
Untangle a list comprehension
1 parent 4d52471 commit 038fccc

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

sounddevice.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1897,10 +1897,8 @@ class DeviceList(tuple):
18971897
__slots__ = ()
18981898

18991899
def __repr__(self):
1900-
idev, odev = [
1901-
dev if isinstance(dev, int) else _get_device_id(dev, kind)
1902-
for kind, dev in zip(('input', 'output'), default.device)
1903-
]
1900+
idev = _get_device_id(default.device['input'], 'input')
1901+
odev = _get_device_id(default.device['output'], 'output')
19041902
digits = len(str(_lib.Pa_GetDeviceCount() - 1))
19051903
hostapi_names = [hostapi['name'] for hostapi in query_hostapis()]
19061904
text = '\n'.join(

0 commit comments

Comments
 (0)