summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--storage/devicetree.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/storage/devicetree.py b/storage/devicetree.py
index d788e37a8..5c4df8ea6 100644
--- a/storage/devicetree.py
+++ b/storage/devicetree.py
@@ -1365,10 +1365,12 @@ class DeviceTree(object):
initcb = lambda: True
else:
description = device.description or device.model
- bypath = os.path.basename(deviceNameToDiskByPath(device.name))
+ bypath = deviceNameToDiskByPath(device.name)
if bypath:
+ bypath = os.path.basename(bypath)
details = "\n\nDevice details:\n%s" % (bypath,)
else:
+ bypath = device.name
details = ""
initcb = lambda: self.intf.questionInitializeDisk(bypath,