mirror of
https://github.com/ankitects/anki.git
synced 2025-09-25 09:16:38 -04:00
Truncate logged fields
This commit is contained in:
parent
382d7417a8
commit
b0d97454a8
1 changed files with 4 additions and 2 deletions
|
@ -70,9 +70,11 @@ impl Note {
|
||||||
.into_fields()
|
.into_fields()
|
||||||
.into_iter()
|
.into_iter()
|
||||||
.map(|field| {
|
.map(|field| {
|
||||||
strip_html_preserving_media_filenames(&field)
|
let mut reduced = strip_html_preserving_media_filenames(&field)
|
||||||
.get_owned()
|
.get_owned()
|
||||||
.unwrap_or(field)
|
.unwrap_or(field);
|
||||||
|
reduced.truncate(80);
|
||||||
|
reduced
|
||||||
})
|
})
|
||||||
.collect(),
|
.collect(),
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue