devmgr: if only one device is plugged, use it

This commit is contained in:
ThomasV 2016-08-31 15:15:55 +02:00
parent 16ed48d52d
commit 323188b963
1 changed files with 2 additions and 0 deletions

View File

@ -469,6 +469,8 @@ class DeviceMgr(ThreadJob, PrintError):
if not handler.yes_no_question(msg):
raise UserCancelled()
devices = None
if len(infos) == 1:
return infos[0]
# select device by label
for info in infos:
if info.label == keystore.label: