mirror of
https://github.com/optim-enterprises-bv/databunker.git
synced 2025-11-02 02:48:05 +00:00
Add auth to backup command
This commit is contained in:
@@ -134,6 +134,9 @@ func (e mainEnv) index(w http.ResponseWriter, r *http.Request) {
|
||||
}
|
||||
|
||||
func (e mainEnv) backupDB(w http.ResponseWriter, r *http.Request, ps httprouter.Params) {
|
||||
if e.enforceAuth(w, r, nil) == false {
|
||||
return
|
||||
}
|
||||
w.WriteHeader(200)
|
||||
e.db.backupDB(w)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user