mirror of
https://github.com/restic/rest-server.git
synced 2025-12-06 17:15:45 -08:00
Address linter issues
This commit is contained in:
6
mux.go
6
mux.go
@@ -12,10 +12,6 @@ import (
|
||||
"github.com/restic/rest-server/quota"
|
||||
)
|
||||
|
||||
const (
|
||||
GiB = 1024 * 1024 * 1024
|
||||
)
|
||||
|
||||
func (s *Server) debugHandler(next http.Handler) http.Handler {
|
||||
return http.HandlerFunc(
|
||||
func(w http.ResponseWriter, r *http.Request) {
|
||||
@@ -70,6 +66,8 @@ func NewHandler(server *Server) (http.Handler, error) {
|
||||
}
|
||||
}
|
||||
|
||||
const GiB = 1024 * 1024 * 1024
|
||||
|
||||
if server.MaxRepoSize > 0 {
|
||||
log.Printf("Initializing quota (can take a while)...")
|
||||
qm, err := quota.New(server.Path, server.MaxRepoSize)
|
||||
|
||||
Reference in New Issue
Block a user