From 6b00b9dea7e378c5533e275e0250cfe8c73b4315 Mon Sep 17 00:00:00 2001 From: Zapic <45936772+KawaiiZapic@users.noreply.github.com> Date: Sat, 21 Nov 2020 13:02:36 +0800 Subject: [PATCH] Fixed #3 --- static/js/main.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/static/js/main.js b/static/js/main.js index 7c01ac6..468aed4 100644 --- a/static/js/main.js +++ b/static/js/main.js @@ -83,8 +83,8 @@ feed.addEventListener("load", function () { xml.querySelectorAll("feed entry").forEach(function (v,i){ if(i > 7){ return; } data.push({ - "link": v.querySelector("link").href, - "timestamp": dateParser(v.querySelector("published").innerHTML), + "link": v.querySelector("link").getAttribute("href"), + "timestamp": v.querySelector("published").innerHTML.slice(0,10), "title": v.querySelector("title").innerHTML }); }); @@ -153,4 +153,4 @@ window.addEventListener("DOMContentLoaded", function () { }); }, {once: true}); }); -console.log("\n %c Present %c By Zapic \n\n", "color: #fff; background: #fb7299; padding:5px 0;", "background: #efefef; padding:5px 0;"); \ No newline at end of file +console.log("\n %c Present %c By Zapic \n\n", "color: #fff; background: #fb7299; padding:5px 0;", "background: #efefef; padding:5px 0;");