We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3e02395 commit f8b012dCopy full SHA for f8b012d
permissions.go
@@ -23,7 +23,7 @@ var HandlerGetPermissionsByUserID func(userID string) ([]Permission, error)
23
24
// IsAuthorized returns error only if the process failed, not if it's not authorized.
25
func IsAuthorized(w http.ResponseWriter, r *http.Request, metadata *string) (userID string, isAuthorized bool, err error) {
26
- endpointKey := r.Method + r.URL.Path
+ endpointKey := r.Method + r.Pattern
27
28
permissionKey, ok := Permissions[endpointKey]
29
if !ok {
0 commit comments