From faf3ee6255dc9f21d4286f462179dedef7ee85da Mon Sep 17 00:00:00 2001 From: kaliko Date: Sat, 26 Sep 2020 18:23:13 +0200 Subject: [PATCH] Fixed bug in history plugin --- sima/plugins/core/history.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sima/plugins/core/history.py b/sima/plugins/core/history.py index b85c0dd..4876eba 100644 --- a/sima/plugins/core/history.py +++ b/sima/plugins/core/history.py @@ -45,7 +45,7 @@ class History(Plugin): def callback_player(self): current = self.player.current last_hist = next(self.sdb.get_history(), None) - if last_hist[3] == current.file: + if last_hist and last_hist[3] == current.file: return if not current: self.log.debug('Cannot add "%s" to history (empty or missing file)', current) -- 2.39.5