From 8aecd9f8681f6124b7f2c2f0d823d00886d85dd7 Mon Sep 17 00:00:00 2001 From: Reinhard Pointner Date: Mon, 31 Oct 2016 07:00:07 +0800 Subject: [PATCH] Fix "Fetch Episodes only" behaviour --- source/net/filebot/ui/rename/RenamePanel.java | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/source/net/filebot/ui/rename/RenamePanel.java b/source/net/filebot/ui/rename/RenamePanel.java index fb52380c..72afbbd7 100644 --- a/source/net/filebot/ui/rename/RenamePanel.java +++ b/source/net/filebot/ui/rename/RenamePanel.java @@ -720,7 +720,7 @@ public class RenamePanel extends JComponent { log.log(Level.WARNING, e, e::toString); } - return emptyList(); + return null; // cancel operation } @Override @@ -859,11 +859,13 @@ public class RenamePanel extends JComponent { // clear names list renameModel.values().clear(); - List remainingFiles = new LinkedList(getFiles(evt)); - if (remainingFiles.isEmpty()) { + // select files + List files = getFiles(evt); + if (files == null) { return; } + List remainingFiles = new LinkedList(files); boolean strict = isStrict(evt); SortOrder order = getSortOrder(evt); Locale locale = getLocale(evt);