fix 'remove entry' when timer debug list is already empty
authorFelix Domke <tmbinc@elitedvb.net>
Fri, 26 Oct 2007 17:01:07 +0000 (17:01 +0000)
committerFelix Domke <tmbinc@elitedvb.net>
Fri, 26 Oct 2007 17:01:07 +0000 (17:01 +0000)
lib/python/Screens/TimerEntry.py

index 4f1d6d6..faf4f30 100644 (file)
@@ -343,7 +343,10 @@ class TimerLog(Screen):
                }, -1)
 
        def deleteEntry(self):
                }, -1)
 
        def deleteEntry(self):
-               self.log_entries.remove(self["loglist"].getCurrent()[1])
+               cur = self["loglist"].getCurrent()
+               if cur is None:
+                       return 
+               self.log_entries.remove(cur[1])
                self.fillLogList()
                self["loglist"].l.setList(self.list)
                self.updateText()
                self.fillLogList()
                self["loglist"].l.setList(self.list)
                self.updateText()