Function autoendpoint::extractors::user::validate_user
source · pub async fn validate_user(
user: &User,
channel_id: &Uuid,
app_state: &AppState,
) -> Result<RouterType, ApiError>
Expand description
Perform some validations on the user, including:
- Validate router type
- (WebPush) Check that the subscription/channel exists
- (WebPush) Drop user if inactive
Returns an enum representing the user’s router type.