needsPermission(permission) → {function}
Returns an Express middleware function that ensures the user making a request has the necessary permission.
Parameters:
Name | Type | Description |
---|---|---|
permission |
String
|
the permission required for the request, such as |
Returns:
- Type:
-
function
- an Express middleware