Handle Wikipedia code blocks in /fetch command (#12780)

This PR extends the `/fetch` command with support for Wikipedia code
blocks.

Release Notes:

- N/A
This commit is contained in:
Marshall Bowers 2024-06-07 12:54:33 -04:00 committed by GitHub
parent 9174858225
commit 834089feb1
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 107 additions and 4 deletions

View file

@ -162,7 +162,7 @@ impl MarkdownWriter {
}
let text = text
.trim_matches(|char| char == '\n' || char == '\r')
.trim_matches(|char| char == '\n' || char == '\r' || char == '\t')
.replace('\n', " ");
self.push_str(&text);