One-line preview of a body (first 160 chars, newlines collapsed).
(body: &str)
| 935 | |
| 936 | /// One-line preview of a body (first 160 chars, newlines collapsed). |
| 937 | fn preview(body: &str) -> String { |
| 938 | let flat: String = body.split_whitespace().collect::<Vec<_>>().join(" "); |
| 939 | truncate_chars(&flat, 160) |
| 940 | } |
| 941 | |
| 942 | // Tests |
| 943 |