Skip to main content

device_turn_message

Function device_turn_message 

Source
pub fn device_turn_message(body: &str) -> String
Expand description

The text an agent receives for a message the user sent from a paired device: what they typed, as a plain user turn with no header (the record stored beside it says where it came from, viewer::origin). Escape sequences and invisible characters are dropped and marker delimiters quoted, as in every delivered body, so the text can’t pose as a jekt, a broadcast or a system note. The caller keeps it under MAX_MESSAGE_LENGTH, so nothing is cut.