mirror of
https://github.com/coder/coder.git
synced 2025-07-09 11:45:56 +00:00
fix(audit): properly set old workspace in putWorkspaceTTL (#4251)
This commit is contained in:
@ -638,6 +638,7 @@ func (api *API) putWorkspaceTTL(rw http.ResponseWriter, r *http.Request) {
|
|||||||
})
|
})
|
||||||
)
|
)
|
||||||
defer commitAudit()
|
defer commitAudit()
|
||||||
|
aReq.Old = workspace
|
||||||
|
|
||||||
if !api.Authorize(r, rbac.ActionUpdate, workspace) {
|
if !api.Authorize(r, rbac.ActionUpdate, workspace) {
|
||||||
httpapi.ResourceNotFound(rw)
|
httpapi.ResourceNotFound(rw)
|
||||||
|
Reference in New Issue
Block a user