Skip to content
Merged
Prev Previous commit
Next Next commit
Fmt
  • Loading branch information
Emyrk committed May 5, 2023
commit a63c9039b01777402ba3ef14e7709fd275364237
4 changes: 1 addition & 3 deletions enterprise/cli/workspaceproxy.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,7 @@ func (r *RootCmd) workspaceProxy() *clibase.Cmd {
}

func (r *RootCmd) regenerateProxyToken() *clibase.Cmd {
var (
formatter = newUpdateProxyResponseFormatter()
)
formatter := newUpdateProxyResponseFormatter()
client := new(codersdk.Client)
cmd := &clibase.Cmd{
Use: "regenerate-token <name|id>",
Expand Down
8 changes: 4 additions & 4 deletions enterprise/coderd/workspaceproxy.go
Original file line number Diff line number Diff line change
Expand Up @@ -416,16 +416,16 @@ func (api *API) workspaceProxyRegister(rw http.ResponseWriter, r *http.Request)
// associated with it. The audit log commitAudit() function ignores
// the audit log if there is no user id. We should find a solution
// to make sure this event is tracked.
//auditor = api.AGPL.Auditor.Load()
// auditor = api.AGPL.Auditor.Load()
//aReq, commitAudit = audit.InitRequest[database.WorkspaceProxy](rw, &audit.RequestParams{
// Audit: *auditor,
// Log: api.Logger,
// Request: r,
// Action: database.AuditActionWrite,
//})
)
//aReq.Old = proxy
//defer commitAudit()
// aReq.Old = proxy
// defer commitAudit()

var req wsproxysdk.RegisterWorkspaceProxyRequest
if !httpapi.Read(ctx, rw, r, &req) {
Expand Down Expand Up @@ -464,7 +464,7 @@ func (api *API) workspaceProxyRegister(rw http.ResponseWriter, r *http.Request)
return
}

//aReq.New = updatedProxy
// aReq.New = updatedProxy
httpapi.Write(ctx, rw, http.StatusCreated, wsproxysdk.RegisterWorkspaceProxyResponse{
AppSecurityKey: api.AppSecurityKey.String(),
})
Expand Down