Skip to main content

verdict

Function verdict 

Source
pub fn verdict(
    request: &Request,
    here: &str,
    now_ms: i64,
    ledger: &Ledger,
    region: Option<&Region>,
) -> Verdict
Expand description

The never-twice decision, step for step: another phone’s; decided already (the ledger holds the key, whatever the sharing read again); refused (refusal); written before the ledger’s mark; dated ahead of the phone’s clock; older than EXPIRY_MS; else sent. The time written is corrected by how far the writer’s clock may run ahead (Request::ahead, measured by the writer as an upper bound: a request looks older, never younger).