Expand hn to hackernews

This commit is contained in:
Yarmo Mackenbach 2020-08-07 11:25:30 +02:00
parent fe84a18f7e
commit 1e61abd248

View file

@ -481,7 +481,7 @@ async function verifyProof(url, fingerprint) {
} }
// HN // HN
if (/^https:\/\/news.ycombinator.com/.test(url)) { if (/^https:\/\/news.ycombinator.com/.test(url)) {
output.type = "hn"; output.type = "hackernews";
match = url.match(/https:\/\/news.ycombinator.com\/user\?id=(.*)/); match = url.match(/https:\/\/news.ycombinator.com\/user\?id=(.*)/);
output.display = match[1]; output.display = match[1];
output.proofUrlFetch = `https://hacker-news.firebaseio.com/v0/user/${match[1]}.json`; output.proofUrlFetch = `https://hacker-news.firebaseio.com/v0/user/${match[1]}.json`;