server: tweak cloudflare and prusa slurp config
This commit is contained in:
parent
b06cbd1381
commit
47b1875022
@ -180,10 +180,10 @@ pub async fn thread(pool: &PgPool, thread_id: String) -> Result<Thread, ServerEr
|
|||||||
Selector::parse("div.entry-content").unwrap(),
|
Selector::parse("div.entry-content").unwrap(),
|
||||||
],
|
],
|
||||||
"blog.prusa3d.com".to_string() => vec![
|
"blog.prusa3d.com".to_string() => vec![
|
||||||
Selector::parse("article.content").unwrap(),
|
Selector::parse("article.content .post-block").unwrap(),
|
||||||
],
|
],
|
||||||
"blog.cloudflare.com".to_string() => vec![
|
"blog.cloudflare.com".to_string() => vec![
|
||||||
Selector::parse(".author-lists").unwrap(),
|
Selector::parse(".author-lists .author-name-tooltip").unwrap(),
|
||||||
Selector::parse(".post-full-content").unwrap()
|
Selector::parse(".post-full-content").unwrap()
|
||||||
],
|
],
|
||||||
"engineering.fb.com".to_string() => vec![
|
"engineering.fb.com".to_string() => vec![
|
||||||
@ -213,11 +213,11 @@ pub async fn thread(pool: &PgPool, thread_id: String) -> Result<Thread, ServerEr
|
|||||||
Box::new(FrameImages),
|
Box::new(FrameImages),
|
||||||
Box::new(AddOutlink),
|
Box::new(AddOutlink),
|
||||||
Box::new(EscapeHtml),
|
Box::new(EscapeHtml),
|
||||||
Box::new(InlineStyle),
|
|
||||||
Box::new(SanitizeHtml {
|
Box::new(SanitizeHtml {
|
||||||
cid_prefix: "",
|
cid_prefix: "",
|
||||||
base_url: &link,
|
base_url: &link,
|
||||||
}),
|
}),
|
||||||
|
Box::new(InlineStyle),
|
||||||
];
|
];
|
||||||
for t in body_tranformers.iter() {
|
for t in body_tranformers.iter() {
|
||||||
if t.should_run(&link, &body) {
|
if t.should_run(&link, &body) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user