mirror of
https://github.com/naruxde/revpimodio2.git
synced 2025-11-08 22:03:53 +01:00
Speicherzeit der piCtory Datei wird in Klasse App verarbeitet
raise IndexError bei __getitem__
This commit is contained in:
@@ -63,7 +63,7 @@ class DeviceList(object):
|
||||
@return Gefundenes <class 'Device'>-Objekt"""
|
||||
if type(key) == int:
|
||||
if key not in self.__dict_position:
|
||||
raise KeyError("no device on position {0}".format(key))
|
||||
raise IndexError("no device on position {0}".format(key))
|
||||
return self.__dict_position[key]
|
||||
else:
|
||||
return getattr(self, key)
|
||||
|
||||
Reference in New Issue
Block a user