Allows the request through iff both left and right allow it.
Allows the request through iff both left and right allow it.
Example usage:
Nap.auth(
StructuredAccessControl.and(Auth.superuser, Auth.admin)).get(ctx => ???)
If there is only one error, it is ignored. If there are two, the left one masks the right one.
Allows the request through as long as at least one of Access Controllers would allow the request.
Allows the request through as long as at least one of Access Controllers would allow the request.
The parse results are exposed to user code as a tuple containing options. At least one of the options must be a Some.
A left-biased combinator that allows the request if either the left or the right access control allow it.
A left-biased combinator that allows the request if either the left or the right access control allow it.
Example usage:
Nap.auth(
StructuredAccessControl.either(Auth.superuser, Auth.admin)).get(ctx => ???)
If there is only one error, it is ignored. If there are two, the right one masks the left one.