project inspection test

This commit is contained in:
Vladimir Krivosheev
2016-06-24 15:37:57 +02:00
parent 749c810539
commit cad5710c3e
@@ -37,6 +37,7 @@ import org.jdom.JDOMException
import org.jdom.Parent
import java.io.IOException
import java.nio.file.Files
import java.nio.file.NoSuchFileException
import java.nio.file.Path
import java.nio.file.attribute.BasicFileAttributes
@@ -111,10 +112,14 @@ open class FileBasedStorage(file: Path,
try {
attributes = Files.readAttributes(file, BasicFileAttributes::class.java)
}
catch (e: IOException) {
catch (e: NoSuchFileException) {
LOG.debug(e) { "Document was not loaded for $fileSpec, doesn't exists" }
return null
}
catch (e: IOException) {
processReadException(e)
return null
}
try {
if (!attributes.isRegularFile) {