From 3a034a07548e470b799f503122a75f5192933d7f Mon Sep 17 00:00:00 2001 From: boyska Date: Tue, 22 Aug 2017 10:32:43 +0200 Subject: [PATCH] FIX leftover files from filtered out events fixes #3 --- larigira/mpc.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/larigira/mpc.py b/larigira/mpc.py index 9cef93a..e35b2d3 100644 --- a/larigira/mpc.py +++ b/larigira/mpc.py @@ -160,6 +160,9 @@ class Player: filterok, reason = self.enqueue_filter(songs) if not filterok: self.log.debug('Ignoring <%s>, filtered: %s', nicks, reason) + # delete those files + for uri in reversed(songs['uris']): + self.tmpcleaner.watch(uri.strip()) return mpd_client = self._get_mpd() for uri in reversed(songs['uris']):