mirror of
https://github.com/Suwayomi/Suwayomi-Server.git
synced 2026-07-13 15:54:35 -05:00
fix URI exception
This commit is contained in:
@@ -59,9 +59,7 @@ fun applicationSetup() {
|
||||
try {
|
||||
val dataConfFile = File("${applicationDirs.dataRoot}/server.conf")
|
||||
if (!dataConfFile.exists()) {
|
||||
val inpStream = File(
|
||||
Main::class.java.getResource("/server-reference.conf").toURI()
|
||||
).inputStream()
|
||||
val inpStream = Main::class.java.getResourceAsStream("/server-reference.conf")
|
||||
val outStream = dataConfFile.outputStream()
|
||||
|
||||
inpStream.copyTo(outStream)
|
||||
@@ -69,7 +67,9 @@ fun applicationSetup() {
|
||||
inpStream.close()
|
||||
outStream.close()
|
||||
}
|
||||
} catch (e: Exception) {}
|
||||
} catch (e: Exception) {
|
||||
e.printStackTrace()
|
||||
}
|
||||
|
||||
makeDataBaseTables()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user