Skip to main content

OrgSource

Trait OrgSource 

Source
pub trait OrgSource: 'static {
    // Required method
    fn organization_id(request: &HttpRequest) -> Result<Option<Id>, AuthError>;
}
Expand description

Where an actix-web extractor finds the organization. axum’s counterpart is crate::extract::OrgSource.

Required Methods§

Source

fn organization_id(request: &HttpRequest) -> Result<Option<Id>, AuthError>

The organization id, or None for the session’s active organization.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl OrgSource for Active

Source§

impl<P: PathParam> OrgSource for FromPath<P>

The organization id in the path segment P::NAME. A route without that segment is a programming error and answers 500.