fix: remove duplicate entry from link elements (#273)

This commit is contained in:
hoilc
2020-05-08 11:53:54 +08:00
committed by GitHub
parent efc81f8ab8
commit 627fa8de56
+4 -2
View File
@@ -61,8 +61,10 @@ export function getPageRSS() {
title: links[i].getAttribute('title') || defaultTitle,
image,
};
pageRSS.push(feed);
unique.save(feed.url);
if (!unique.check(feed.url)) {
pageRSS.push(feed);
unique.save(feed.url);
}
}
}
}