MCPcopy Index your code
hub / github.com/coder/coder / As

Method As

coderd/rbac/error.go:108–113  ·  view source on GitHub ↗

As implements the errors.As interface.

(target interface{})

Source from the content-addressed store, hash-verified

106
107// As implements the errors.As interface.
108func (*UnauthorizedError) As(target interface{}) bool {
109 if _, ok := target.(*UnauthorizedError); ok {
110 return true
111 }
112 return false
113}
114
115// correctCancelError will return the correct error for a canceled context. This
116// is because rego changes a canceled context to a topdown.CancelErr. This error

Calls

no outgoing calls