diff --git a/src/moz_readability/mod.rs b/src/moz_readability/mod.rs index 7af37f7..705fa55 100644 --- a/src/moz_readability/mod.rs +++ b/src/moz_readability/mod.rs @@ -1248,8 +1248,7 @@ impl Readability { let srcset = node_attr.get("srcset"); let class = node_attr.get("class"); if (src.is_some() || srcset.is_some()) - && class.is_some() - && !class.unwrap().contains("lazy") + && class.and_then(|classname| classname.find("lazy")).is_none() { continue; }