Documentation ¶
Index ¶
- Constants
- func PermissionCheck(perm permission.Permission, a app.App) func(next http.Handler) http.Handler
- func RoomMemberCheck(a app.App) func(next http.Handler) http.Handler
- func SendInternalError(w http.ResponseWriter, r *http.Request)
- func SendUnauthorized(w http.ResponseWriter, r *http.Request)
- func SessionFromContext(ctx context.Context) *app.Session
- func UserIdFromContext(ctx context.Context) model.UserId
- func UserValidator(a app.App) func(next http.Handler) http.Handler
Constants ¶
View Source
const SessionCtxKey = "session"
View Source
const UserIdCtxKey = "user_id"
Variables ¶
This section is empty.
Functions ¶
func PermissionCheck ¶
func PermissionCheck(perm permission.Permission, a app.App) func(next http.Handler) http.Handler
func SendInternalError ¶
func SendInternalError(w http.ResponseWriter, r *http.Request)
func SendUnauthorized ¶
func SendUnauthorized(w http.ResponseWriter, r *http.Request)
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.