mirror of
https://github.com/aptly-dev/aptly.git
synced 2026-06-05 05:20:34 +00:00
replace io/ioutil
fixes golangci-lint errors
This commit is contained in:
+1
-2
@@ -2,7 +2,6 @@ package api
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
"os"
|
||||
"sort"
|
||||
@@ -488,7 +487,7 @@ func apiMirrorsUpdate(c *gin.Context) {
|
||||
task.TempDownPath, e = pp.GenerateTempPath(task.File.Filename)
|
||||
} else {
|
||||
var file *os.File
|
||||
file, e = ioutil.TempFile("", task.File.Filename)
|
||||
file, e = os.CreateTemp("", task.File.Filename)
|
||||
if e == nil {
|
||||
task.TempDownPath = file.Name()
|
||||
file.Close()
|
||||
|
||||
Reference in New Issue
Block a user