mirror of
https://github.com/mitb-archive/filebot
synced 2024-11-18 07:15:07 -05:00
Ignore invalid exclude list lines
This commit is contained in:
parent
2d31f81367
commit
69a58b8185
@ -3,12 +3,14 @@ package net.filebot.util;
|
|||||||
import static java.nio.charset.StandardCharsets.*;
|
import static java.nio.charset.StandardCharsets.*;
|
||||||
import static java.util.Collections.*;
|
import static java.util.Collections.*;
|
||||||
import static java.util.stream.Collectors.*;
|
import static java.util.stream.Collectors.*;
|
||||||
|
import static net.filebot.Logging.*;
|
||||||
import static net.filebot.util.FileUtilities.*;
|
import static net.filebot.util.FileUtilities.*;
|
||||||
|
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.net.URI;
|
import java.net.URI;
|
||||||
import java.nio.file.Files;
|
import java.nio.file.Files;
|
||||||
|
import java.nio.file.InvalidPathException;
|
||||||
import java.nio.file.Path;
|
import java.nio.file.Path;
|
||||||
import java.nio.file.Paths;
|
import java.nio.file.Paths;
|
||||||
import java.nio.file.StandardOpenOption;
|
import java.nio.file.StandardOpenOption;
|
||||||
@ -156,7 +158,13 @@ public class FileSet extends AbstractSet<Path> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public void load(File f) throws IOException {
|
public void load(File f) throws IOException {
|
||||||
streamLines(f).forEach(this::add);
|
streamLines(f).forEach(path -> {
|
||||||
|
try {
|
||||||
|
add(Paths.get(path));
|
||||||
|
} catch (InvalidPathException e) {
|
||||||
|
debug.warning(e::toString);
|
||||||
|
}
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
public void append(File f, Collection<?>... paths) throws IOException {
|
public void append(File f, Collection<?>... paths) throws IOException {
|
||||||
|
Loading…
Reference in New Issue
Block a user