On alias resolution in PathResource, ignore NoSuchFileException (its a
valid and common path for 404 requested resources)
This commit is contained in:
parent
51e4885911
commit
38501a9e97
|
@ -32,6 +32,7 @@ import java.nio.file.DirectoryStream;
|
|||
import java.nio.file.Files;
|
||||
import java.nio.file.InvalidPathException;
|
||||
import java.nio.file.LinkOption;
|
||||
import java.nio.file.NoSuchFileException;
|
||||
import java.nio.file.Path;
|
||||
import java.nio.file.StandardOpenOption;
|
||||
import java.nio.file.attribute.FileTime;
|
||||
|
@ -71,6 +72,10 @@ public class PathResource extends Resource
|
|||
return realUri;
|
||||
}
|
||||
}
|
||||
catch (NoSuchFileException e)
|
||||
{
|
||||
// Ignore
|
||||
}
|
||||
catch (IOException e)
|
||||
{
|
||||
// TODO: reevaluate severity level
|
||||
|
|
Loading…
Reference in New Issue