feat: remove site wide perms from creating a workspace (#17296)

Creating a workspace required `read` on site wide `user`. 
Only organization permissions should be required.
This commit is contained in:
Steven Masley
2025-04-09 14:35:43 -05:00
committed by GitHub
parent a03a54dd14
commit 0b58798a1a
8 changed files with 392 additions and 135 deletions

10
coderd/httpapi/noop.go Normal file
View File

@ -0,0 +1,10 @@
package httpapi
import "net/http"
// NoopResponseWriter is a response writer that does nothing.
type NoopResponseWriter struct{}
func (NoopResponseWriter) Header() http.Header { return http.Header{} }
func (NoopResponseWriter) Write(p []byte) (int, error) { return len(p), nil }
func (NoopResponseWriter) WriteHeader(int) {}