Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion internal/reader/sanitizer/sanitizer.go
Original file line number Diff line number Diff line change
Expand Up @@ -467,7 +467,12 @@ func hasRequiredAttributes(tagName string, attributes []string) bool {
case "iframe":
return slices.Contains(attributes, "src")
case "source", "img":
return slices.Contains(attributes, "src") || slices.Contains(attributes, "srcset")
for _, attribute := range attributes {
if attribute == "src" || attribute == "srcset" {
return true
}
}
return false
default:
return true
}
Expand Down