WorkspaceRBACFromContext attempts to retrieve the workspace RBAC object from context.
(ctx context.Context)
| 36 | |
| 37 | // WorkspaceRBACFromContext attempts to retrieve the workspace RBAC object from context. |
| 38 | func WorkspaceRBACFromContext(ctx context.Context) (rbac.Object, bool) { |
| 39 | obj, ok := ctx.Value(workspaceRBACContextKey{}).(rbac.Object) |
| 40 | return obj, ok |
| 41 | } |
no test coverage detected