Skip to main content

writes_common_key

Function writes_common_key 

Source
fn writes_common_key(peer: Option<&str>, key: &str) -> bool
Expand description

Whether the common event fields account for key — the required three always, and "p" only when a peer was actually read from it.

"p" is optional, and optional means it can also be unusable: a "p" that is not text leaves TraceEvent::peer None, and the entry then belongs in TraceEvent::extra like any other value the reader could not use. Excluding the key unconditionally would delete it instead.