headless_lms_models::user_research_consents

Function upsert

Source
pub async fn upsert(
    conn: &mut PgConnection,
    pkey_policy: PKeyPolicy<Uuid>,
    user_id: Uuid,
    research_consent: bool,
) -> ModelResult<UserResearchConsent>