From 9f7c628890f5c7fa51435ae0039d8d2ecc4244cb Mon Sep 17 00:00:00 2001 From: Reinhard Pointner Date: Sun, 19 May 2013 16:37:52 +0000 Subject: [PATCH] * make -non-strict less strict so it never aborts when the options a fairly reasonable even though there is no apparent good match --- source/net/sourceforge/filebot/cli/CmdlineOperations.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/source/net/sourceforge/filebot/cli/CmdlineOperations.java b/source/net/sourceforge/filebot/cli/CmdlineOperations.java index 3fe8f1c8..fc580072 100644 --- a/source/net/sourceforge/filebot/cli/CmdlineOperations.java +++ b/source/net/sourceforge/filebot/cli/CmdlineOperations.java @@ -888,7 +888,11 @@ public class CmdlineOperations implements CmdlineInterface { if (strict) { throw new Exception("Multiple options: Force auto-select requires non-strict matching: " + searchResults); } else { - throw new Exception("Unable to auto-select search result: " + searchResults); + if (searchResults.size() > 5) { + throw new Exception("Unable to auto-select search result: " + searchResults); + } else { + return new ArrayList(searchResults); + } } }