Commits

Byron Clark committed b6106c1

Better output when printing Device.

  • Participants
  • Parent commits e76fea8

Comments (0)

Files changed (1)

File udiskie/device.py

     def __init__(self, bus, device_path):
         self.log = logging.getLogger('udiskie.device.Device')
         self.bus = bus
+        self.device_path = device_path
         self.device = self.bus.get_object(UDISKS_OBJECT, device_path)
 
+    def __str__(self):
+        return self.device_path
+
     def _get_property(self, property):
         return self.device.Get(UDISKS_DEVICE_INTERFACE, property,
                                dbus_interface=DBUS_PROPS_INTERFACE)