Skip to content

Commit 96c5246

Browse files
committed
fixed error + pylint-tweaks
1 parent 8044efc commit 96c5246

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

adafruit_display_shapes/sparkline.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,7 @@ def __init__(
100100
self._x = x
101101
self._y = y
102102
self._redraw = True # _redraw: redraw primitives
103+
self._last = [] # _last: last point of sparkline
103104

104105
super().__init__(x=x, y=y) # self is a group of lines
105106

@@ -182,7 +183,7 @@ def _plotline(
182183
self.append(Line(x_1, y_1, x_2, y_2, self.color)) # plot the line
183184
self._last = [x_2, value]
184185

185-
# pylint: disable= too-many-branches, too-many-nested-blocks
186+
# pylint: disable= too-many-branches, too-many-nested-blocks, too-many-locals, too-many-statements
186187

187188
def update(self) -> None:
188189
"""Update the drawing of the sparkline."""
@@ -271,8 +272,6 @@ def update(self) -> None:
271272
adj_last_value,
272273
adj_x_2,
273274
adj_value,
274-
self.y_bottom,
275-
self.y_top,
276275
)
277276

278277
last_value = value # store value for the next iteration

0 commit comments

Comments
 (0)