mirror of
https://github.com/drakkan/sftpgo.git
synced 2025-12-07 06:40:54 +03:00
WebClient/REST API: add sharing support
This commit is contained in:
@@ -55,6 +55,7 @@ func addAPIKey(w http.ResponseWriter, r *http.Request) {
|
||||
apiKey.ID = 0
|
||||
apiKey.KeyID = ""
|
||||
apiKey.Key = ""
|
||||
apiKey.LastUseAt = 0
|
||||
err = dataprovider.AddAPIKey(&apiKey, claims.Username, util.GetIPFromRemoteAddress(r.RemoteAddr))
|
||||
if err != nil {
|
||||
sendAPIResponse(w, r, err, "", getRespStatus(err))
|
||||
|
||||
Reference in New Issue
Block a user