Skip to main content

rekey_peer_or_self_review_questions

Function rekey_peer_or_self_review_questions 

Source
fn rekey_peer_or_self_review_questions(
    questions: Vec<CmsPeerOrSelfReviewQuestion>,
    source_config_id: Uuid,
    target_config_id: Uuid,
) -> Vec<CmsPeerOrSelfReviewQuestion>
Expand description

Gives questions fresh ids pointing at target_config_id when it differs from source_config_id (i.e. they are being cloned onto a different config); otherwise returns them untouched so the upsert reuses the existing rows.