Skip to content

Commit 7848c6e

Browse files
author
caternuson
committed
change to IndexError
1 parent cf105bf commit 7848c6e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

adafruit_mpr121.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ def __init__(self, i2c, address=MPR121_I2CADDR_DEFAULT):
107107

108108
def __getitem__(self, key):
109109
if key < 0 or key > 11:
110-
raise ValueError('Pin must be a value 0-11.')
110+
raise IndexError('Pin must be a value 0-11.')
111111
if self._channels[key] is None:
112112
self._channels[key] = MPR121_Channel(self, key)
113113
return self._channels[key]

0 commit comments

Comments
 (0)