Skip to content

Commit 945b566

Browse files
hotfix for predictions plotting
1 parent 0c383e1 commit 945b566

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

packetraven/plotting.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ def __init__(
3434
raise NotImplementedError(f'unsupported plotting variable "{variable}"')
3535

3636
self.packet_tracks = packet_tracks
37-
self.predictions = predictions
37+
self.predictions = predictions if predictions is not None else {}
3838
self.variable = variable
3939

4040
self.window.protocol('WM_DELETE_WINDOW', self.window.iconify)
@@ -48,7 +48,7 @@ def update(
4848
):
4949
if packet_tracks is not None:
5050
self.packet_tracks.update(packet_tracks)
51-
if packet_tracks is not None:
51+
if predictions is not None:
5252
self.predictions.update(predictions)
5353

5454
if len(self.packet_tracks) > 0:

0 commit comments

Comments
 (0)