Skip to main content

press_from_toast

Function press_from_toast 

Source
fn press_from_toast(
    state: &AppState,
    r: &Arc<Router>,
    notification_id: &str,
    action: &str,
    proof: Option<&str>,
) -> Option<String>
Expand description

A button on a pending shutdown’s toast (or a sensitive operation’s): the same calls the pane banner’s RPCs make, so exactly one of this and the window running out wins. Which request it is about comes from srv’s own record of the notification, never from the press, and is the request the toast was raised for: a press on a toast whose request already ended finds too_late and cannot touch a newer request for the same block. None when the id is no live shutdown notification.