From a7878b0eba864cd404284cbf98d151d48dc2dc89 Mon Sep 17 00:00:00 2001 From: Adrian Sampson Date: Tue, 3 Feb 2015 09:50:36 -0800 Subject: [PATCH] A couple of explanatory comments for #1292 --- beetsplug/filefilter.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/beetsplug/filefilter.py b/beetsplug/filefilter.py index fbb23aae7..432388c5a 100644 --- a/beetsplug/filefilter.py +++ b/beetsplug/filefilter.py @@ -50,10 +50,15 @@ class FileFilterPlugin(BeetsPlugin): if len(items_to_import) > 0: task.items = items_to_import else: + # Returning an empty list of tasks from the handler + # drops the task from the rest of the importer pipeline. return [] + elif isinstance(task, SingletonImportTask): if not self.file_filter(task.item['path']): return [] + + # If not filtered, return the original task unchanged. return [task] def file_filter(self, full_path):