mirror of
https://github.com/Suwayomi/Suwayomi-Server.git
synced 2026-07-05 20:04:36 -05:00
Use temporary file for H2 migration tools download (#2169)
This commit is contained in:
@@ -14,7 +14,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).
|
||||
- (**Manga/API**) Return partial responses for Manga And Chapters query
|
||||
|
||||
### Fixed
|
||||
- .
|
||||
- (**Database/H2**) Use temporary file for H2 migration tools download
|
||||
|
||||
## [v2.3.2232] - 2026-07-03
|
||||
|
||||
|
||||
@@ -130,9 +130,12 @@ object H2Migration {
|
||||
)
|
||||
}
|
||||
|
||||
output.outputStream().use { out ->
|
||||
val tmp = output.resolveSibling(output.name + ".tmp")
|
||||
tmp.outputStream().use { out ->
|
||||
response.body.byteStream().copyTo(out)
|
||||
}
|
||||
tmp.copyTo(output)
|
||||
tmp.deleteExisting()
|
||||
}
|
||||
|
||||
logger.info { "Saved: ${output.absolutePathString()}" }
|
||||
|
||||
Reference in New Issue
Block a user