1
0

Let's, actually, directly assign to uploadDirSize.

This commit is contained in:
Alexander Andreev 2023-05-21 21:12:23 +04:00
parent 7e1b56bbc5
commit 31d2c4fd21
Signed by: Arav
GPG Key ID: D22A817D95815393

View File

@ -112,12 +112,10 @@ func main() {
logUpload.Reopen(config.Log.Upload) logUpload.Reopen(config.Log.Upload)
logDownload.Reopen(config.Log.Download) logDownload.Reopen(config.Log.Download)
case <-uploadDirNotify: case <-uploadDirNotify:
sz, err := utils.DirectorySize(config.Uploads.Directory) uploadDirSize, err = utils.DirectorySize(config.Uploads.Directory)
if err != nil { if err != nil {
logErr.Println("failed to get uploads directory size:", err) logErr.Println("failed to get uploads directory size:", err)
} }
uploadDirSize = sz
} }
} }
}() }()