Pārlūkot izejas kodu

feat(sanitizer): consider images of size 0x0 as pixel trackers

jvoisin 1 gadu atpakaļ
vecāks
revīzija
152ef578d2
1 mainītis faili ar 1 papildinājumiem un 1 dzēšanām
  1. 1 1
      internal/reader/sanitizer/sanitizer.go

+ 1 - 1
internal/reader/sanitizer/sanitizer.go

@@ -440,7 +440,7 @@ func isPixelTracker(tagName string, attributes []html.Attribute) bool {
 	hasWidth := false
 	hasWidth := false
 
 
 	for _, attribute := range attributes {
 	for _, attribute := range attributes {
-		if attribute.Val == "1" {
+		if attribute.Val == "1" || attribute.Val == "0" {
 			switch attribute.Key {
 			switch attribute.Key {
 			case "height":
 			case "height":
 				hasHeight = true
 				hasHeight = true