mirror of
https://github.com/aptly-dev/aptly.git
synced 2026-06-10 06:14:22 +00:00
go1.24: fix lint, unit and system tests
- development env: base on debian trixie with go1.24 - lint: run with default config - fix lint errors - fix unit tests - fix system test
This commit is contained in:
+2
-2
@@ -122,7 +122,7 @@ func apiFilesUpload(c *gin.Context) {
|
||||
AbortWithJSONError(c, 500, err)
|
||||
return
|
||||
}
|
||||
defer src.Close()
|
||||
defer func() { _ = src.Close() }()
|
||||
|
||||
destPath := filepath.Join(path, filepath.Base(file.Filename))
|
||||
dst, err := os.Create(destPath)
|
||||
@@ -130,7 +130,7 @@ func apiFilesUpload(c *gin.Context) {
|
||||
AbortWithJSONError(c, 500, err)
|
||||
return
|
||||
}
|
||||
defer dst.Close()
|
||||
defer func() { _ = dst.Close() }()
|
||||
|
||||
_, err = io.Copy(dst, src)
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user