From 34bd0164d300c1bd755c078f1127c644a0037677 Mon Sep 17 00:00:00 2001 From: KawaiiZapic Date: Tue, 17 Nov 2020 13:05:08 +0800 Subject: [PATCH] Remove debug code & limit XML feed --- static/js/main.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/static/js/main.js b/static/js/main.js index 2858043..fbb1386 100644 --- a/static/js/main.js +++ b/static/js/main.js @@ -69,10 +69,10 @@ feed.addEventListener("load", function () { if(!xml){ throw new Error(); } - window.xml = xml; xml = xml.querySelectorAll("channel item"); var data = []; - xml.forEach(function (v){ + xml.forEach(function (v,i){ + if(i > 7){ return; } data.push({ "link": v.querySelector("link").innerHTML, "timestamp": dateParser(v.querySelector("pubDate").innerHTML),